keychain: add xsession integration
This commit is contained in:
parent
5992c1b469
commit
a0ab0b16fe
|
@ -84,6 +84,15 @@ in
|
||||||
Whether to enable Zsh integration.
|
Whether to enable Zsh integration.
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
|
enableXsessionIntegration = mkOption {
|
||||||
|
default = true;
|
||||||
|
type = types.bool;
|
||||||
|
visible = pkgs.stdenv.hostPlatform.isLinux;
|
||||||
|
description = ''
|
||||||
|
Whether to run keychain from your <filename>~/.xsession</filename>.
|
||||||
|
'';
|
||||||
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
config = mkIf cfg.enable {
|
config = mkIf cfg.enable {
|
||||||
|
@ -97,5 +106,8 @@ in
|
||||||
programs.zsh.initExtra = mkIf cfg.enableZshIntegration ''
|
programs.zsh.initExtra = mkIf cfg.enableZshIntegration ''
|
||||||
eval "$(${shellCommand})"
|
eval "$(${shellCommand})"
|
||||||
'';
|
'';
|
||||||
|
xsession.initExtra = mkIf cfg.enableXsessionIntegration ''
|
||||||
|
eval "$(${shellCommand})"
|
||||||
|
'';
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue