2013-09-18 18:01:16 +02:00
|
|
|
#!/bin/bash
|
|
|
|
|
|
|
|
|
|
if [ -d /etc/X11/xinit/xinitrc.d ]; then
|
|
|
|
|
for f in /etc/X11/xinit/xinitrc.d/*; do
|
|
|
|
|
[ -x "$f" ] && . "$f"
|
|
|
|
|
done
|
|
|
|
|
unset f
|
|
|
|
|
fi
|
|
|
|
|
|
|
|
|
|
[ -f /etc/xprofile ] && source /etc/xprofile
|
|
|
|
|
[ -f ~/.xprofile ] && source ~/.xprofile
|
|
|
|
|
|
2014-04-12 00:30:24 +02:00
|
|
|
export LANG=en_US.UTF-8
|
|
|
|
|
|
2013-09-18 19:27:36 +02:00
|
|
|
# keyboard options
|
|
|
|
|
keyboard_layout=de
|
2013-09-20 15:23:54 +02:00
|
|
|
keyboard_variant=nodeadkeys
|
2013-09-18 19:27:36 +02:00
|
|
|
keyboard_repeat_delay=150
|
|
|
|
|
keyboard_repeat_speed=30
|
|
|
|
|
|
2014-04-17 19:35:04 +02:00
|
|
|
# path and options for the wallpaper changer script
|
|
|
|
|
path_wallchanger="$HOME/.i3/scripts/wallchanger.bash"
|
|
|
|
|
wallpaper_directory="$HOME/pictures/wallpaper/misc"
|
|
|
|
|
wallpaper_logfile="$HOME/.i3/logs/wallpaper.log"
|
|
|
|
|
wallpaper_fallback="$HOME/.i3/data/wallpaper/"
|
|
|
|
|
wallpaper_interval="900"
|
|
|
|
|
|
|
|
|
|
# redshift settings
|
|
|
|
|
redshift_lat_long="49.5:11"
|
|
|
|
|
redshift_colortemp="5500:3700"
|
|
|
|
|
|
|
|
|
|
# start the pulseaudio volume control tray applet
|
|
|
|
|
pasystray &
|
|
|
|
|
|
|
|
|
|
# start dropbox
|
|
|
|
|
dropboxd &
|
|
|
|
|
|
|
|
|
|
# start the wallpaper changer
|
|
|
|
|
$path_wallchanger "$wallpaper_directory" "$wallpaper_interval" "$wallpaper_fallback" > "$wallpaper_logfile" &
|
|
|
|
|
|
|
|
|
|
# start redshift
|
|
|
|
|
redshift-gtk -l "$redshift_lat_long" -t "$redshift_colortemp" &
|
|
|
|
|
|
|
|
|
|
# set keyboard layout
|
|
|
|
|
setxkbmap -layout "$keyboard_layout" -variant "$keyboard_variant" &
|
|
|
|
|
|
|
|
|
|
# set key repeat delay
|
|
|
|
|
xset r rate "$keyboard_repeat_delay" "$keyboard_repeat_speed" &
|
|
|
|
|
|
2013-09-18 18:01:16 +02:00
|
|
|
# execute the host-specific .xinitrc-addition
|
|
|
|
|
hostfile="$HOME/.xinitrc.d/$(hostname).xinitrc"
|
|
|
|
|
[[ -f "$hostfile" ]] && bash "$hostfile" &
|
|
|
|
|
|
2014-04-17 19:35:04 +02:00
|
|
|
[[ -f ~/.Xresources ]] && xrdb -merge ~/.Xresources &
|
2013-09-18 19:27:36 +02:00
|
|
|
|
2014-04-17 19:35:04 +02:00
|
|
|
LOG="$HOME/.i3/logs/i3.log"
|
|
|
|
|
LOGOLD="$HOME/.i3/logs/i3.log.old"
|
2013-09-18 19:27:36 +02:00
|
|
|
|
2014-04-17 19:35:04 +02:00
|
|
|
# simple logrotate so we can still get info about the last session
|
|
|
|
|
[[ -f "$LOG" ]] && mv -f "$LOG" "$LOGOLD"
|
2013-09-18 19:27:36 +02:00
|
|
|
|
2014-03-31 14:30:22 +02:00
|
|
|
SESSION_CONF=$(bash "$HOME/.i3/scripts/genconfig.bash")
|
|
|
|
|
exec i3 -c "$SESSION_CONF" >> ~/.i3/logs/i3.log
|