Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/bin/sh
- #
- # ~/.xinitrc
- # executed by startx
- # To autologin with systemd & Arch:
- # 1. cp /usr/lib/systemd/system/getty@.service /etc/systemd/system/autologin@.service
- # 2. ln -s /etc/systemd/system/autologin@.service /etc/systemd/system/getty.target.wants/getty@tty1.service
- # 3. /etc/systemd/system/autologin@.service :Edit: ExecStart=-/sbin/agetty -a USERNAME %I $TERM
- # 4. Add the following if statment to .zprofile for zsh, or .bash_profile for bash
- #
- # if [ -z "$DISPLAY" ] && [ -n "$XDG_VTNR" ] && [ "$XDG_VTNR" -eq 1 ]; then
- # exec startx
- # fi
- # Session to run if none given
- session=${1:-openbox}
- # source /etc/X11/xinit/xinitrc.d
- if [[ -d /etc/X11/xinit/xinitrc.d ]]; then
- for f in /etc/X11/xinit/xinitrc.d/*; do
- [[ -x $f ]] && . $f
- done
- unset f
- fi
- # source .xprofile
- if [[ -f $HOME/.xprofile ]]; then
- source $HOME/.xprofile
- fi
- # To run different WM, call this with:
- # startx ~/.xinitrc SESSION eg. startx ~/.xinitrc openbox
- case $session in
- i3|i3wm)
- exec i3
- ;;
- bsp|bspwm)
- exec bspwm
- ;;
- xfce|xfce4)
- exec startxfce4
- ;;
- openbox)
- exec openbox-session
- ;;
- *)
- exec $1 # Lastly, if unknown, try running $1
- esac
- numlockx &
- exec openbox-session
- xrdb ~/.Xresources
- urxvtd -q -f -o &
- rxset s 60 60
- xset m 1/1
- xset r rate 200 30
- setxkbmap -option caps:escape
- xrander --dpi 192
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement