Eqivalent of environment.homeBinInPath for home-manager?

Is there an equivalent of environment.homeBinInPath for home-manager or, even better, a way to append to $PATH ?

https://nix-community.github.io/home-manager/options.html#opt-home.sessionPath

“noisypine via NixOS Discourse” nixos1@discoursemail.com writes:

Is there an equivalent of environment.homeBinInPath for home-manager or, even better, a way to append to $PATH ?

Try home.sessionPath

That worked, but for some reason, it only works on a virtual terminal. When using qterminal in openbox, the added path is not appended.

Ah then you probably need programs.<shell>.enable = true, source
"$HOME/.nix-profile/etc/profile.d/hm-session-vars.sh" or
xsession.enable = true.

1 Like

Thanks. This is what ended up working

xsession.enable = true;    
xsession.windowManager.command = "openbox";

home.sessionPath is nice. But it appends to the end of $PATH, rather than prepend to the head like homeBInInPath. I wonder why is this design decision.