[misc] cleanup .xinitrc

This commit is contained in:
Klesh Wong 2020-09-30 23:04:51 +08:00
parent e861b20070
commit 6c614150fa

View File

@ -55,6 +55,8 @@ cd ~/Projects/suckless/dwm && sudo rm -f config.h && sudo make clean install
# config xinit to start for dwm
rm ~/.xinitrc
cat <<EOT > ~/.xinitrc
#!/bin/sh
export QT_QPA_PLATFORMTHEME="qt5ct"
export GTK2_RC_FILES="$HOME/.gtkrc-2.0"
@ -62,24 +64,19 @@ export XMODIFIERS="@im=ibus"
export QT_IM_MODULE=ibus
export GTK_IM_MODULE=xim
# xrandr --setprovideroutputsource modesetting NVIDIA-0
# xrandr --auto
xrdb ~/.Xresources
# auto lock after 300 seconds
xset s 300
systemd-lock-handler /usr/local/bin/slock
#xsetroot -cursor_name left_ptr
# setup gnome keyring
dbus-update-activation-environment --systemd DISPLAY
eval $(/usr/bin/gnome-keyring-daemon --start --components=pkcs11,secrets,ssh)
export SSH_AUTH_SOCK
# load monitors profile
autorandr --change --force
# restart dwm if it existed without error
while :; do
ssh-agent dwm 2>/tmp/dwm.log || break
done