forked from nix-community/home-manager
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
programs.neovim: add extraLuaConfig (nix-community#3639)
* programs.neovim: add extraLuaConfig Add a configuration option to add custom lua configuration lines to `lua.init`. * apply review: formatting * apply review: fix test
- Loading branch information
1 parent
1333c39
commit a110c1c
Showing
3 changed files
with
37 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,4 +5,5 @@ | |
|
||
# waiting for a nixpkgs patch | ||
neovim-no-init = ./no-init.nix; | ||
neovim-extra-lua-init = ./extra-lua-init.nix; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
{ config, lib, pkgs, ... }: | ||
|
||
with lib; | ||
|
||
{ | ||
config = { | ||
programs.neovim = { | ||
enable = true; | ||
|
||
extraLuaConfig = '' | ||
-- extraLuaConfig | ||
''; | ||
}; | ||
nmt.script = '' | ||
nvimFolder="home-files/.config/nvim" | ||
assertFileContent "$nvimFolder/init.lua" ${ | ||
pkgs.writeText "init.lua-expected" '' | ||
-- extraLuaConfig | ||
'' | ||
} | ||
''; | ||
}; | ||
} |