From 8d2eeb617cee6834bb3f61600248072866b2bd43 Mon Sep 17 00:00:00 2001 From: "flyingscorpio@arch-desktop" Date: Thu, 23 Jul 2020 15:25:15 +0200 Subject: [PATCH] Remove sddm and setup xinit instead --- dotfiles/bash/profile | 4 ++++ dotfiles/xinitrc | 35 +++++++++++++++++++++++++++++++++++ dotfiles/xserverrc | 2 ++ 3 files changed, 41 insertions(+) create mode 100644 dotfiles/xinitrc create mode 100644 dotfiles/xserverrc diff --git a/dotfiles/bash/profile b/dotfiles/bash/profile index c449249..2107cc6 100644 --- a/dotfiles/bash/profile +++ b/dotfiles/bash/profile @@ -9,3 +9,7 @@ fi export PATH="$HOME/.cargo/bin:$PATH" export PATH="$PATH:$HOME/.local/bin" + +if systemctl -q is-active graphical.target && [[ ! $DISPLAY && $XDG_VTNR -eq 1 ]]; then + exec startx +fi diff --git a/dotfiles/xinitrc b/dotfiles/xinitrc new file mode 100644 index 0000000..8eb6a7c --- /dev/null +++ b/dotfiles/xinitrc @@ -0,0 +1,35 @@ +#!/bin/sh + +userresources=$HOME/.Xresources +usermodmap=$HOME/.Xmodmap +sysresources=/etc/X11/xinit/.Xresources +sysmodmap=/etc/X11/xinit/.Xmodmap + +# merge in defaults and keymaps + +if [ -f $sysresources ]; then + xrdb -merge $sysresources +fi + +if [ -f $sysmodmap ]; then + xmodmap $sysmodmap +fi + +if [ -f "$userresources" ]; then + xrdb -merge "$userresources" +fi + +if [ -f "$usermodmap" ]; then + xmodmap "$usermodmap" +fi + +# start some nice programs + +if [ -d /etc/X11/xinit/xinitrc.d ] ; then + for f in /etc/X11/xinit/xinitrc.d/?*.sh ; do + [ -x "$f" ] && . "$f" + done + unset f +fi + +exec i3 diff --git a/dotfiles/xserverrc b/dotfiles/xserverrc new file mode 100644 index 0000000..ced148b --- /dev/null +++ b/dotfiles/xserverrc @@ -0,0 +1,2 @@ +#!/bin/sh +exec /usr/bin/X -nolisten tcp "$@" vt"$XDG_VTNR"