1
0
Fork 0
mirror of https://github.com/nix-community/home-manager.git synced 2025-04-09 18:44:14 +00:00
This commit is contained in:
Julio César 2025-03-20 06:09:20 -03:00 committed by GitHub
commit 83bc4981c7
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 8 additions and 2 deletions

View file

@ -419,7 +419,10 @@ in {
home.packages = [ cfg.finalPackage ];
home.sessionVariables = mkIf cfg.defaultEditor { EDITOR = "nvim"; };
home.sessionVariables = mkIf cfg.defaultEditor {
EDITOR = getBin
(pkgs.writeShellScript "editor" "exec ${getBin cfg.package}/bin/nvim");
};
home.shellAliases = mkIf cfg.vimdiffAlias { vimdiff = "nvim -d"; };

View file

@ -174,7 +174,10 @@ in {
home.packages = [ cfg.package ];
home.sessionVariables = mkIf cfg.defaultEditor { EDITOR = "vim"; };
home.sessionVariables = mkIf cfg.defaultEditor {
EDITOR = getBin
(pkgs.writeShellScript "editor" "exec ${getBin cfg.package}/bin/vim");
};
programs.vim = {
package = vim;