chore: improve documentation of init module

dev
LeMarsu 2026-03-16 01:22:09 +01:00
parent f9afe7fa31
commit 85fa8f4d1f
1 changed files with 9 additions and 4 deletions

View File

@ -57,7 +57,7 @@ in
type = with types; nullOr (either path str);
default = null;
description = ''
Lua code to call before plugins loaded
Lua code to call before loading any plugins or even any sloth-flake calls.
'';
};
@ -65,7 +65,7 @@ in
type = with types; nullOr (either path str);
default = null;
description = ''
Lua code called after init but before import
Lua code called after every non-lazy plugins init but before loading any plugin.
'';
};
@ -73,7 +73,7 @@ in
type = with types; nullOr (either path str);
default = null;
description = ''
Lua code called after all plugins are loaded
Lua code called after all plugins are loaded and configured.
'';
};
@ -90,7 +90,12 @@ in
option = mkOption {
default = null;
description = ''
init.lua configuration
init.lua configuration can be a string, a path or attribute set.
The attribute set form will call sloth-flake for you and load your
plugins. It allows you to hook at different moments in the loading
process of your plugins: before everything, after all plugins init code
is called and after everything is loaded.
'';
type = with types; coercedTo (nullOr (oneOf [path str])) coerceToModule self.module;
example = ./init.lua;