From 21590d40c1575ff77c96bbb0c7b151cfa788e100 Mon Sep 17 00:00:00 2001 From: Joscha Date: Sun, 31 Oct 2021 10:18:28 +0000 Subject: [PATCH] home-environment: document escaping of home.sessionPath --- modules/home-environment.nix | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/modules/home-environment.nix b/modules/home-environment.nix index abfc3e7ee..b3e904e5b 100644 --- a/modules/home-environment.nix +++ b/modules/home-environment.nix @@ -274,11 +274,21 @@ in type = with types; listOf str; default = [ ]; example = [ - ".git/safe/../../bin" + "$HOME/.local/bin" "\${xdg.configHome}/emacs/bin" - "~/.local/bin" + ".git/safe/../../bin" ]; - description = "Extra directories to add to PATH."; + description = '' + Extra directories to add to PATH. + + + + These directories are added to the PATH variable in a + double-quoted context, so expressions like $HOME are + expanded by the shell. However, since expressions like ~ or + * are escaped, they will end up in the PATH + verbatim. + ''; }; home.sessionVariablesExtra = mkOption {