-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.xinitrc
executable file
·67 lines (48 loc) · 1.78 KB
/
.xinitrc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
#!/bin/sh
# We are using xinit-xsession package to use .xinitrc as the sesssion configuration
# xinitrc also runs automatically when startx is run.
# . ~/.xprofile
XDG_CACHE_HOME="${HOME}/.cache"
# We need quotes to preserve multiline output
PID_NAMES="$(ps -C xcompmgr,dunst,mpd,unclutter,dwm)"
# START_XCOMPMGR=0
# START_DUNST=0
# START_MPD=0
# START_UNCLUTTER=0
START_DWM=0
# If no colors are cached just run setbg command
setbg "${HOME}/.local/share/bg"
# If process name doesn't already exist, start it.
# This is useful if making changes to this script and logging out is too excessive...
if ! $(echo -n "${PID_NAMES}" | grep -q "xcompmgr"); then
xcompmgr & # For transparency
fi
if ! $(echo -n "${PID_NAMES}" | grep -q "dunst"); then
dunst & # Notifications
fi
if ! $(echo -n "${PID_NAMES}" | grep -q "mpd"); then
mpd & # Music Player Daemon
fi
if ! $(echo -n "${PID_NAMES}" | grep -q "unclutter"); then
unclutter & # Remove mouse when it's idling
fi
if ! $(echo -n "${PID_NAMES}" | grep -q "dwm"); then
START_DWM=1 # DWM
fi
xset r rate 300 55 & # Speed xrate up
remaps & # run the remaps script, switching caps/esc and more; check it for more info
lxpolkit & # Run a polkit daemon
# Ensure the dbus environment is running properly
systemctl --user import-environment DISPLAY XAUTHORITY
if which dbus-update-activation-environment >/dev/null 2>&1; then
dbus-update-activation-environment DISPLAY XAUTHORITY
fi
# Start a LIBRESPOT speaker
# librespot --name "LIBRESPOT" --device-type computer -b 320 -u "[email protected]" -p "Inabottle11!" --initial-volume 100 &
keyledsd -c /home/mathias/.config/keyledsd.conf &
exec dbus-launch \
--exit-with-session \
--sh-syntax \
--autolaunch=$(cat /var/lib/dbus/machine-id) \
ssh-agent \
dwm