mirror of
https://github.com/nix-community/home-manager
synced 2024-12-22 17:59:48 +01:00
opam: add fish integration (#3422)
This commit is contained in:
parent
c94c9c342f
commit
5589b28e66
1 changed files with 12 additions and 0 deletions
|
@ -34,6 +34,14 @@ in {
|
||||||
Whether to enable Zsh integration.
|
Whether to enable Zsh integration.
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
|
enableFishIntegration = mkOption {
|
||||||
|
default = true;
|
||||||
|
type = types.bool;
|
||||||
|
description = ''
|
||||||
|
Whether to enable Fish integration.
|
||||||
|
'';
|
||||||
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
config = mkIf cfg.enable {
|
config = mkIf cfg.enable {
|
||||||
|
@ -46,5 +54,9 @@ in {
|
||||||
programs.zsh.initExtra = mkIf cfg.enableZshIntegration ''
|
programs.zsh.initExtra = mkIf cfg.enableZshIntegration ''
|
||||||
eval "$(${cfg.package}/bin/opam env --shell=zsh)"
|
eval "$(${cfg.package}/bin/opam env --shell=zsh)"
|
||||||
'';
|
'';
|
||||||
|
|
||||||
|
programs.fish.shellInit = mkIf cfg.enableFishIntegration ''
|
||||||
|
eval "$(${cfg.package}/bin/opam env --shell=fish)"
|
||||||
|
'';
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue