mirror of
https://github.com/nix-community/home-manager.git
synced 2025-11-08 19:46:05 +01:00
programs.neovim: dont wrap init.vim (#2058)
since we want to write it ourself in ~/.config/nvim/init.vim
This commit is contained in:
parent
95da56b783
commit
c7e79b5337
4 changed files with 32 additions and 7 deletions
|
|
@ -51,8 +51,7 @@ let
|
|||
(map (x: if x ? plugin && x.optional == true then x.plugin else null)
|
||||
cfg.plugins);
|
||||
};
|
||||
customRC = pkgs.lib.concatMapStrings pluginConfig cfg.plugins
|
||||
+ cfg.extraConfig;
|
||||
beforePlugins = "";
|
||||
};
|
||||
|
||||
extraMakeWrapperArgs = lib.optionalString (cfg.extraPackages != [ ])
|
||||
|
|
@ -242,11 +241,14 @@ in {
|
|||
|
||||
home.packages = [ cfg.finalPackage ];
|
||||
|
||||
xdg.configFile."nvim/init.vim".text = neovimConfig.neovimRcContent;
|
||||
xdg.configFile = mkIf (neovimConfig.neovimRcContent != "") {
|
||||
"nvim/init.vim".text = neovimConfig.neovimRcContent;
|
||||
};
|
||||
programs.neovim.finalPackage = pkgs.wrapNeovimUnstable cfg.package
|
||||
(neovimConfig // {
|
||||
wrapperArgs = (lib.escapeShellArgs neovimConfig.wrapperArgs) + " "
|
||||
+ extraMakeWrapperArgs;
|
||||
wrapRc = false;
|
||||
});
|
||||
|
||||
programs.bash.shellAliases = mkIf cfg.vimdiffAlias { vimdiff = "nvim -d"; };
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue