fixed home manager session variables
This commit is contained in:
parent
f2ebfeb4ea
commit
fa3a7f5786
3 changed files with 16 additions and 2 deletions
|
|
@ -146,6 +146,7 @@
|
||||||
overrides = {
|
overrides = {
|
||||||
kylekrein-server.hostname = "kylekrein.com";
|
kylekrein-server.hostname = "kylekrein.com";
|
||||||
};
|
};
|
||||||
|
exclude = ["kylekrein-wsl-wm"];
|
||||||
};
|
};
|
||||||
|
|
||||||
outputs-builder = channels: {
|
outputs-builder = channels: {
|
||||||
|
|
|
||||||
|
|
@ -19,14 +19,18 @@ in rec {
|
||||||
mkDeploy = {
|
mkDeploy = {
|
||||||
self,
|
self,
|
||||||
overrides ? {},
|
overrides ? {},
|
||||||
|
exclude ? [],
|
||||||
}: let
|
}: let
|
||||||
hosts = self.nixosConfigurations or {};
|
hosts =
|
||||||
|
builtins.removeAttrs
|
||||||
|
(self.nixosConfigurations or {})
|
||||||
|
exclude;
|
||||||
names = builtins.attrNames hosts;
|
names = builtins.attrNames hosts;
|
||||||
nodes =
|
nodes =
|
||||||
lib.foldl (
|
lib.foldl (
|
||||||
result: name: let
|
result: name: let
|
||||||
host = hosts.${name};
|
host = hosts.${name};
|
||||||
user = host.config.user.name or null;
|
user = overrides.user or null;
|
||||||
inherit (host.pkgs) system;
|
inherit (host.pkgs) system;
|
||||||
in
|
in
|
||||||
result
|
result
|
||||||
|
|
|
||||||
9
modules/home/fixes/sessionVariables/default.nix
Normal file
9
modules/home/fixes/sessionVariables/default.nix
Normal file
|
|
@ -0,0 +1,9 @@
|
||||||
|
#https://github.com/nix-community/home-manager/issues/1011
|
||||||
|
{config, ...}: let
|
||||||
|
homeManagerSessionVars = "${config.home.profileDirectory}/etc/profile.d/hm-session-vars.sh";
|
||||||
|
in {
|
||||||
|
programs.bash.enable = !config.programs.zsh.enable && !config.programs.fish.enable && !config.programs.nushell.enable;
|
||||||
|
programs.bash.initExtra = ''
|
||||||
|
source "${homeManagerSessionVars}"
|
||||||
|
'';
|
||||||
|
}
|
||||||
Loading…
Add table
Add a link
Reference in a new issue