On Sun, Nov 17, 2019 at 5:22 AM Leo Prikler <email@example.com>
I took a closer look at this, and currently Zsh users have /etc/profile
included in their environment by virtue of a default $HOME/.zprofile, which
is created in their home directory when they are created (via `useradd` and
I'm a little stuck to know what to do here -- if we source /etc/profile in
/etc/zprofile, then we risk sourcing it twice for users who have the
current default ~/.zprofile already in their home directories`. OTOH, if
users come to Guix System with their own pre-existing home directory, then
they may well struggle --- as I did -- because important environment
variables aren't set by their established ~/.zshrc, ~/.zprofile or
I *think* the right thing to do is to drop the current /etc/skel/.zprofile
and establish that /etc/zprofile (and other shells) should source
/etc/profile . Guix System does a lot of setup in /etc/profile including
including $GUIX_PROFILE/etc/profile. It would be best if this
automatically happened, whatever is going on in individual home
directories. I'm a Guix newbie though, so I'm happy to take advice!
Archlinux has a one-line /etc/zprofile which sources /etc/profile ; Debian
does not; I have not checked other distributions, but I could.
A couple of Guix commits where the current behavior was established:
Author: Chris Marusich <firstname.lastname@example.org>
system: Rename .zlogin to .zprofile.
Reported by Meiyo Peng <email@example.com>.
* gnu/system/shadow.scm (default-skeletons): Rename zlogin to zprofile.
Author: Sou Bunnbu (宋文武) <firstname.lastname@example.org>
system: Add skeleton '.zlogin'.
* gnu/system/shadow.scm (default-skeletons): Add .zlogin.