mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-23 15:33:13 +00:00
19 lines
397 B
Nix
19 lines
397 B
Nix
{ config, lib, pkgs, ... }:
|
|
|
|
let
|
|
cfg = config.programs.zsh.zsh-autoenv;
|
|
in {
|
|
options = {
|
|
programs.zsh.zsh-autoenv = {
|
|
enable = lib.mkEnableOption "zsh-autoenv";
|
|
package = lib.mkPackageOption pkgs "zsh-autoenv" { };
|
|
};
|
|
};
|
|
|
|
config = lib.mkIf cfg.enable {
|
|
programs.zsh.interactiveShellInit = ''
|
|
source ${cfg.package}/share/zsh-autoenv/autoenv.zsh
|
|
'';
|
|
};
|
|
}
|