From 768ce91d46cc3a06c5842c91334bd88350ceab56 Mon Sep 17 00:00:00 2001 From: Maximilian Friedersdorff Date: Mon, 31 Oct 2016 09:26:01 +0000 Subject: [PATCH] Choose keyboard/screen layout based on hostname --- X/.xinitrc | 22 +++++++++++++++++----- 1 file changed, 17 insertions(+), 5 deletions(-) diff --git a/X/.xinitrc b/X/.xinitrc index 7897989..0c2dc6b 100644 --- a/X/.xinitrc +++ b/X/.xinitrc @@ -16,13 +16,25 @@ fi # Load .Xresources xrdb -merge ~/.Xresources &> /dev/null -setxkbmap -variant colemak gb -xmodmap -e "keycode 66 = Control_L Control_L Control_L Control_L" -xmodmap -e "add Control = Control_L Control_R" +# Set keyboard layout +case $HOSTNAME in + palladium|beryllium) + setxkbmap -variant colemak gb + xmodmap -e "keycode 66 = Control_L Control_L Control_L Control_L" + xmodmap -e "keycode 135 = Control_R Control_R Control_R Control_R" + xmodmap -e "add Control = Control_L Control_R" + ;; + *) +esac # Set screen layout -xrandr --output VGA1 --right-of HDMI1 - +case $HOSTNAME in + beryllium) + xrandr --output VGA1 --right-of HDMI1 + ;; + *) + ;; +esac # Set java font option export _JAVA_OPTIONS="-Dawt.useSystemAAFontSettings=on" -- 2.46.2