mirror of
https://github.com/outbackdingo/hyprcosmic-session.git
synced 2026-08-25 07:20:17 +00:00
e6f8d560ab446a2010965c5f0446c48714bf05c5
The greeter starts this script with what pam and systemd put in the environment and nothing else. start-cosmic re-execs itself through $SHELL to pick up /etc/profile and the user's login files; not doing the same here is why the two sessions disagreed about the environment. Measured here, the difference is XDG_DATA_DIRS: empty without this, and with it the two flatpak exports directories that hold the .desktop files and icons the launcher reads. PATH is unchanged either way -- /etc/profile only appends what is missing. Differs from upstream in two ways. The recursion guard is an exported variable rather than a positional --in-login-shell flag, because a flag has to survive being quoted through another shell to be seen on the way back in, and if it ever failed to, the login would hang instead of failing; an exported variable survives exec by definition. And it uses bash's own `exec -l` rather than an extra `bash -c` hop, since this script is already bash. First in the file, deliberately: the login files may set XDG_CACHE_HOME, which is where the log goes, so this happens while there is nothing to lose. Verified the log still rotates exactly once per login. see: https://github.com/pop-os/cosmic-session/issues/23
Description
Fork of pop-os/cosmic-session for HyprCosmic: an autostart profile, a start-hyprcosmic entry point, and an install that leaves stock COSMIC intact
126 KiB
Languages
Rust
61.7%
Shell
28.9%
Just
5.7%
Nix
3.7%