1
0
Fork 0
mirror of https://github.com/nix-community/home-manager synced 2024-12-24 02:39:48 +01:00

direnv: add fish support

This commit is contained in:
adisbladis 2018-08-27 19:21:01 +08:00 committed by Robert Helgesson
parent 2548c43175
commit 99a0e2469b
No known key found for this signature in database
GPG key ID: 36BDAA14C2797E89

View file

@ -29,6 +29,14 @@ in
Whether to enable Zsh integration.
'';
};
enableFishIntegration = mkOption {
default = true;
type = types.bool;
description = ''
Whether to enable Fish integration.
'';
};
};
config = mkIf cfg.enable {
@ -46,5 +54,9 @@ in
programs.zsh.initExtra = mkIf cfg.enableZshIntegration ''
eval "$(${pkgs.direnv}/bin/direnv hook zsh)"
'';
programs.fish.shellInit = mkIf cfg.enableFishIntegration ''
eval (${pkgs.direnv}/bin/direnv hook fish)
'';
};
}