-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
NixOS and home-manager does not update session variables in Wayland + GNOME until reboot #755
Comments
💭 What is the different of variables and sessionVariables? |
pkill and re-login does not fix pkill -SIGQUIT gnome-shell pkill -SIGQUIT gdm |
systemctl restart display-manager also does not resolve |
This is much frustrated when I was struggling with #886 |
https://wiki.archlinux.org/title/Environment_variables#Per_Wayland_session
Updating
|
> bat /home/kachick/.nix-profile/etc/profile.d/hm-session-vars.sh
# Only source this once.
if [ -n "$__HM_SESS_VARS_SOURCED" ]; then return; fi
export __HM_SESS_VARS_SOURCED=1
export EDITOR="/nix/store/h0cn28h7mvkj1vwbdj4zkzkailkwr1i0-helix-24.03/bin/hx"
> echo $__HM_SESS_VARS_SOURCED
1 🤔 |
Might be related to #680? |
https://unix.stackexchange.com/questions/2745/how-to-run-a-script-during-gnome-log-out > lat /etc/gdm
0755 - 10-27 20:21 /etc/gdm
0755 - 10-27 20:21 ├── PostLogin
0777 - 10-27 20:21 │ └── Default -> /etc/static/gdm/PostLogin/Default
0777 - 10-27 20:21 ├── Xsession -> /etc/static/gdm/Xsession
0777 - 10-27 20:21 └── custom.conf -> /etc/static/gdm/custom.conf |
This does not help GH-755 for now. Mostly for UI looks
❄️ ~ zsh 1
> cdnix gnome-session
❄️ /nix/store/9zkcrgjd42wv2ir2bnkfwkg8ms33nbbd-gnome-session-46.0🔒 zsh
> bat bin/gnome-session
#!/nix/store/516kai7nl5dxr792c0nzq0jp8m4zvxpi-bash-5.2p32/bin/sh
if [ "x$XDG_SESSION_TYPE" = "xwayland" ] &&
[ "x$XDG_SESSION_CLASS" != "xgreeter" ] &&
[ -n "$SHELL" ] &&
grep -q "$SHELL" /etc/shells &&
! (echo "$SHELL" | grep -q "false") &&
! (echo "$SHELL" | grep -q "nologin"); then
if [ "$1" != '-l' ]; then
# Make sure the shell actually sets up the environment.
unset __NIXOS_SET_ENVIRONMENT_DONE
exec /nix/store/516kai7nl5dxr792c0nzq0jp8m4zvxpi-bash-5.2p32/bin/bash -c "exec -l '$SH
ELL' -c '$0 -l $*'"
else
shift
fi
fi
SETTING=$(G_MESSAGES_DEBUG='' /nix/store/v6rxay5qhjr4s8dzcb3sr9n0m7kms07g-glib-2.80.2-bin/
bin/gsettings get org.gnome.system.locale region)
REGION=${SETTING#\'}
REGION=${REGION%\'}
if [ -n "$REGION" ]; then
unset LC_TIME LC_NUMERIC LC_MONETARY LC_MEASUREMENT LC_PAPER
if [ "$LANG" != "$REGION" ] ; then
# LC_CTYPE
export LC_NUMERIC=$REGION
export LC_TIME=$REGION
# LC_COLLATE
export LC_MONETARY=$REGION
# LC_MESSAGES
export LC_PAPER=$REGION
# LC_NAME
export LC_ADDRESS=$REGION
export LC_TELEPHONE=$REGION
export LC_MEASUREMENT=$REGION
# LC_IDENTIFICATION
fi
fi
exec /nix/store/9zkcrgjd42wv2ir2bnkfwkg8ms33nbbd-gnome-session-46.0/libexec/gnome-session-
binary "$@" |
Often occurred, latest is f042b85
nix-community/home-manager#1011
After rebooting(relogin?) fixed, but it is annoy (Now my NixOS requires to be rebooted many times than Windows...)
The text was updated successfully, but these errors were encountered: