#!/bin/sh

xrdb "$XDG_CONFIG_HOME/xorg/Xresources"

# Setup display
"$HOME"/.scripts/monctl.sh auto 3000 2000 48 eDP-1 &

# Set default X cursor to arrow
xsetroot -cursor_name left_ptr

# Disable screensaver
xset s off
xset -dpms

# Customize keyboard layout
inputctl.sh -k off
inputctl.sh -k on

# Turn off touchscreen
inputctl.sh -s off

# Daemon starting
dunst &
redshift &

emacs --daemon &
thunar --daemon &

sxhkd "$XDG_CONFIG_HOME/sxhkd/$WM" &
xss-lock -- "$HOME"/.scripts/wm/lock.sh &

[ "$WM" = "bspwm" ] && stalonetray &

exec $WM