feat(nvim): format init.lua
This commit is contained in:
parent
c8f53dfe2e
commit
3180e64085
1 changed files with 12 additions and 5 deletions
|
@ -63,9 +63,7 @@ let
|
|||
);
|
||||
lazySpecs = listToStringMultiLine id (map lazySpecFromPlugin cfg.plugins);
|
||||
lazy = ''
|
||||
require("lazy").setup({
|
||||
${lazySpecs}
|
||||
})
|
||||
require("lazy").setup(${lazySpecs})
|
||||
'';
|
||||
in
|
||||
{
|
||||
|
@ -213,7 +211,17 @@ in
|
|||
else neovide
|
||||
)
|
||||
];
|
||||
|
||||
xdg.configFile."nvim/init.lua" = {
|
||||
source =
|
||||
let
|
||||
text = lib.concatLines [ (builtins.readFile ./options.lua) lazy ];
|
||||
in
|
||||
pkgs.runCommand "init.lua" { inherit text; } ''
|
||||
touch $out
|
||||
echo -n "$text" > $out
|
||||
${getExe pkgs.stylua} $out
|
||||
'';
|
||||
};
|
||||
programs.neovim = {
|
||||
enable = true;
|
||||
package = pkgs.neovim-nightly;
|
||||
|
@ -221,7 +229,6 @@ in
|
|||
vimdiffAlias = true;
|
||||
withNodeJs = true;
|
||||
withPython3 = true;
|
||||
extraLuaConfig = lib.concatLines [ (builtins.readFile ./options.lua) lazy ];
|
||||
extraPython3Packages = ps:
|
||||
let
|
||||
plugins = map (getAttr "plugin") cfg.plugins;
|
||||
|
|
Loading…
Reference in a new issue