-
Notifications
You must be signed in to change notification settings - Fork 0
/
.xinitrc
executable file
·62 lines (50 loc) · 1.39 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
[ -f ~/.Xresources ] && xrdb -merge ~/.Xresources
setxkbmap gb
exists()
{
which "$1" > /dev/null
}
ifexists()
{
exists "$1" || return
"$@"
}
if exists xinput; then
setxprop()
{
device="$1"
propname="$2"
shift 2
prop=`xinput list-props "$device" | grep -v Default | grep "$propname" | sed 's/.*(//;s/).*//'`
xinput set-prop "$device" "$prop" "$@"
}
device=`xinput list | grep 'Synaptics' | sed 's,.*id=,,;s,\t.*,,'`
if [ -z "$device" ]; then
echo "Couldn't find synaptics device" 1>&2
else
setxprop $device "Natural Scrolling Enabled" 1
setxprop $device "Tapping Enabled" 1
setxprop $device "Disable While Typing Enabled" 1
# TODO: format for below is wrong?
# setxprop $device "Scroll Method Enabled" 1 0 0
# setxprop $device "Accel Speed" 1
fi
elif exists synclient; then
synclient VertScrollDelta=-150
synclient HorizScrollDelta=-150
fi
for p in unclutter dunst notify-osd; do
killall "$p" 2> /dev/null
done
ifexists dunst &
ifexists unclutter -idle 1 -jitter 2 -root &
ifexists syndaemon -i 1.0 -K -R -t &
if exists gnome-screensaver; then
gnome-screensaver &
else
ifexists xscreensaver -no-splash &
fi
xgamma -gamma 0.8
#gsettings set org.gnome.desktop.background picture-uri "file://$(dirname $(readlink -f "$0"))/per-environment/laptop-linux/stormboarder.png"
feh --bg-scale "$(dirname $(readlink -f "$0"))/per-environment/laptop-linux/stormboarder.png"
#exec i3