Use xprofile to start necessary init apps

This commit is contained in:
ItsDrike 2021-07-22 22:20:53 +02:00
parent dbd37392b8
commit fe61af8f62
No known key found for this signature in database
GPG key ID: B5F6B41F708C3ADD
2 changed files with 29 additions and 8 deletions

View file

@ -3,4 +3,25 @@
# This file runs when a DM logs you into a graphical session # This file runs when a DM logs you into a graphical session
# if you use startx/xinit this file should also be soruced. # if you use startx/xinit this file should also be soruced.
xrandr --output eDP-1 --auto --output HDMI-1 --auto --left-of eDP-1 # Set monitor order
xrandr --output HDMI-1 --auto --output eDP-1 --right-of HDMI-1 --auto
# Set the background with a custom `setbg` script
setbg &
# xcompmgr to allow transparency
xcompmgr &
# Dunst for notifications
dunst &
# Run network manager applet to show connectivity
nm-applet &
# Run trayer-srg for systemtray bar
# if installed normally, use `trayer`, not `trayer-srg` command
trayer-srg --monitor 0 --edge top --align right --widthtype request --padding 0 --transparent true --tint 0x282c34 --alpha 0 --height 23 &
# Enable running applications from chroot
xhost +local:

View file

@ -314,16 +314,16 @@ myManageHook = composeAll
-- Perform an arbitrary action each time xmonad starts or is restarted -- Perform an arbitrary action each time xmonad starts or is restarted
-- with mod-q. Used by, e.g., XMonad.Layout.PerWorkspace to initialize -- with mod-q. Used by, e.g., XMonad.Layout.PerWorkspace to initialize
-- per-workspace layout choices. -- per-workspace layout choices.
--
-- I don't really use this because I define these applications
-- in ~/.config/x11/xprofile instead, that way it will apply for
-- all WMs, not just for XMonad
myStartupHook :: X () myStartupHook :: X ()
myStartupHook = do myStartupHook = do
spawnOnce "setbg &" -- Automatically run autostart.sh script which will start
spawnOnce "nm-applet &" -- .desktop applications defined in ~/.config/autostart
spawnOnce "dunst &" spawnOnce "$HOME/.config/xmonad/scripts/autostart.sh &"
spawnOnce "trayer-srg --monitor 0 --edge top --align right --widthtype request --padding 0 --transparent true --tint 0x282c34 --alpha 0 --height 23 &"
spawnOnce "$HOME/.config/xmonad/scripts/autostart.sh"
--spawnOnce "emacs --daemon &"
--spawnOnce "urxvtd -q -o -f &"
------------------------------------------------------------------------------- -------------------------------------------------------------------------------
-- Log hook: this sends info to xmobar process(es) -- Log hook: this sends info to xmobar process(es)