Skip to content

Commit

Permalink
xinit
Browse files Browse the repository at this point in the history
  • Loading branch information
Adam Schaefers committed Aug 16, 2017
1 parent d4c80ac commit 59e7852
Show file tree
Hide file tree
Showing 2 changed files with 46 additions and 2 deletions.
37 changes: 35 additions & 2 deletions .xinitrc
@@ -1,5 +1,7 @@
#!/bin/sh

# Adapted from Manjaro's "Proper ~/.xinitrc"
# https://wiki.manjaro.org/index.php?title=Proper_~/.xinitrc_File
if [ -d /etc/X11/xinit/xinitrc.d ]; then
for f in /etc/X11/xinit/xinitrc.d/*; do
[ -x "$f" ] && . "$f"
Expand All @@ -9,19 +11,50 @@ fi

# Load .Xresources (Most login managers do this automatically)
[[ -f ~/.Xresources ]] && xrdb -merge -I$HOME ~/.Xresources

# load notification daemon
dunst &
# load terminal daemon
urxvtd -q -o -f &
# Load compositor
compton --config ~/.config/i3/compton.conf &

# sleep a couple seconds here so intel-driver doesn't garble
# external monitor display settings below...
sleep 2
sleep 3
# set laptop monitor as primary
xrandr --output LVDS1 --mode 1366x768 --rate 60 --primary
# look for external monitor, if found, set it to the left...
xrandr --output VGA1 --mode 1600x900 --rate 60 --left-of LVDS1
# set wallpaper(s)
# Now set wallpaper(s)
nitrogen --restore &

# Load window Manager
exec i3

# Other Window Managers
# exec enlightenment_start
# exec mate-session
# exec xmonad
# exec startlxqt
# exec startlxde
# exec awesome
# exec bspwm
# exec gnome-session
# exec gnome-session --session=gnome-classic
# exec startkde
# exec startxfce4
# exec startfluxbox
# exec openbox-session
# exec cinnamon-session
# exec pekwm
# exec catwm
# exec dwm
# exec startede
# exec icewm-session
# exec jwm
# exec monsterwm
# exec notion
# exec startdde
# deepin-session

11 changes: 11 additions & 0 deletions .xserverrc
@@ -0,0 +1,11 @@
#!/bin/sh

# xserverrc
# https://wiki.archlinux.org/index.php/Xinit#Configuration

# The xserverrc file is a shell script responsible for starting up the X server. Both startx and xinit execute ~/.xserverrc if it exists, startx will use /etc/X11/xinit/xserverrc otherwise.

# In order to maintain an authenticated session with logind and to prevent bypassing the screen locker by switching terminals, Xorg has to be started on the same virtual terminal where the login occurred.[1] Therefore it is recommended to specify vt$XDG_VTNR in the ~/.xserverrc file:

exec /usr/bin/Xorg -nolisten tcp "$@" vt$XDG_VTNR

0 comments on commit 59e7852

Please sign in to comment.