diff options
Diffstat (limited to 'x/xsession.sh')
-rw-r--r-- | x/xsession.sh | 49 |
1 files changed, 33 insertions, 16 deletions
diff --git a/x/xsession.sh b/x/xsession.sh index 6b298048..e0552315 100644 --- a/x/xsession.sh +++ b/x/xsession.sh @@ -1,8 +1,20 @@ -# Custom X session to fit into Debian's way of doing things - -# Load common environment variables -# shellcheck disable=SC1091 -. "$HOME"/.xprofile +# +# Custom i3wm X session to fit into Debian's way of doing things, for use with +# startx(1) or xinit(1). From Debian's `man 1 startx` (xinit dpkg 1.4.0-1): +# +# > Note that in the Debian system, what many people traditionally put in the +# > .xinitrc file should go in .xsession instead; this permits the same X +# > environment to be presented whether startx, xdm, or xinit is used to start +# > the X session. All discussion of the .xinitrc file in the xinit(1) manual +# > page applies equally well to .xsession. +# +# This turns out to be important for having the X session wrappers in /etc/X11 +# on Debian-derived systems do things like dbus daemon and accessibility setup. +# +# At the time of writing, none of my machines running X are using anything +# other than the Debian-derived X startup script layout, so we'll just conform +# to that unless and until I actually need to abstract this. +# # Monitor and wallpaper setup is very machine-specific, and isn't versioned in # here. Neither xrandr(1) nor xwallpaper(1) have config files, so we fake it @@ -30,14 +42,20 @@ xset \ mouse 5/2 0 \ s off -# Start a few daemons if we can; it's OK if they don't exist, but log the -# failed attempt to start them to the errors file. -## compton: Display compositor -compton -b & -## dunst: Message display (libnotify) -dunst & -## unclutter: Hide mouse after inactivity (but not on root window) -unclutter -idle 5 & +# Start a few daemons if we can; it's OK if any of these don't exist, but we'll +# log the failed attempt to start them to the errors file, as a hint that +# I might want to install them. +# +( + # Display compositor + compton + # Message display (libnotify) + dunst + # PulseAudio system tray tool + pasystray + # Hide mouse after inactivity + unclutter +) & # Load all supplementary scripts in ~/.xsession.d for sh in "$HOME"/.xsession.d/*.sh ; do @@ -46,6 +64,5 @@ for sh in "$HOME"/.xsession.d/*.sh ; do done unset -v sh -# Start Debian's configured window manager now that everything's ready; at the -# time of writing, this is normally i3wm -exec x-window-manager +# Become an i3 window manager process, having set everything else up +exec i3 |