Merge pull request #128271 from Kreyren/localBinInPath

authored by

Ben Siraphob and committed by
GitHub
28acaac9 74f12354

+12
+12
nixos/modules/config/shells-environment.nix
··· 126 type = types.bool; 127 }; 128 129 environment.binsh = mkOption { 130 default = "${config.system.build.binsh}/bin/sh"; 131 defaultText = "\${config.system.build.binsh}/bin/sh"; ··· 197 ${optionalString cfg.homeBinInPath '' 198 # ~/bin if it exists overrides other bin directories. 199 export PATH="$HOME/bin:$PATH" 200 ''} 201 ''; 202
··· 126 type = types.bool; 127 }; 128 129 + environment.localBinInPath = mkOption { 130 + description = '' 131 + Add ~/.local/bin/ to $PATH 132 + ''; 133 + default = false; 134 + type = types.bool; 135 + }; 136 + 137 environment.binsh = mkOption { 138 default = "${config.system.build.binsh}/bin/sh"; 139 defaultText = "\${config.system.build.binsh}/bin/sh"; ··· 205 ${optionalString cfg.homeBinInPath '' 206 # ~/bin if it exists overrides other bin directories. 207 export PATH="$HOME/bin:$PATH" 208 + ''} 209 + 210 + ${optionalString cfg.localBinInPath '' 211 + export PATH="$HOME/.local/bin:$PATH" 212 ''} 213 ''; 214