2eafb8192e
GitOrigin-RevId: 176e455371a8371586e8a3ff0d56ee9f3ca2324e
34 lines
811 B
Nix
34 lines
811 B
Nix
{ config, lib, pkgs, ... }:
|
|
|
|
with lib;
|
|
|
|
{
|
|
config = {
|
|
programs.neovim = {
|
|
enable = true;
|
|
extraConfig = ''
|
|
let g:hmExtraConfig='HM_EXTRA_CONFIG'
|
|
'';
|
|
plugins = with pkgs.vimPlugins; [
|
|
vim-nix
|
|
{
|
|
plugin = vim-commentary;
|
|
config = ''
|
|
let g:hmPlugins='HM_PLUGINS_CONFIG'
|
|
'';
|
|
}
|
|
];
|
|
extraLuaPackages = [ pkgs.lua51Packages.luautf8 ];
|
|
};
|
|
|
|
nmt.script = ''
|
|
vimout=$(mktemp)
|
|
echo "redir >> /dev/stdout | echo g:hmExtraConfig | echo g:hmPlugins | redir END" \
|
|
| ${pkgs.neovim}/bin/nvim -es -u "$TESTED/home-files/.config/nvim/init.lua" \
|
|
> "$vimout"
|
|
assertFileContains "$vimout" "HM_EXTRA_CONFIG"
|
|
assertFileContains "$vimout" "HM_PLUGINS_CONFIG"
|
|
'';
|
|
};
|
|
}
|
|
|