--- /dev/null
+#!/bin/sh
+
+set -e
+
+MAIN=$(xrandr | grep eDP | cut -f1 -d" ")
+if [ "${MAIN}" = "" ]; then
+ echo "Could not find main display."
+ exit 1
+fi
+
+OTHER=$(xrandr | grep "\<connected\>" | grep -v eDP | cut -f1 -d" ")
+if [ "${OTHER}" = "" ]; then
+ echo "Could not find external display."
+ exit 1
+fi
+
+echo "Set ${MAIN} as mirror of ${OTHER}"
+
+xrandr --output ${OTHER} --auto --output ${MAIN} --same-as ${OTHER} --primary
--- /dev/null
+#!/bin/sh
+
+set -e
+
+MAIN=$(xrandr | grep eDP | cut -f1 -d" ")
+if [ "${MAIN}" = "" ]; then
+ echo "Could not find main display."
+ exit 1
+fi
+
+OTHER=$(xrandr | grep "\<connected\>" | grep -v eDP | cut -f1 -d" ")
+if [ "${OTHER}" = "" ]; then
+ echo "Could not find external display."
+ exit 1
+fi
+
+echo "Bring ${OTHER} right of ${MAIN}"
+
+xrandr --output ${MAIN} --auto --primary; xrandr --output ${OTHER} --auto; xrandr --output ${OTHER} --auto --right-of ${MAIN}
--- /dev/null
+#!/bin/sh
+
+set -e
+
+MAIN=$(xrandr | grep eDP | cut -f1 -d" ")
+if [ "${MAIN}" = "" ]; then
+ echo "Could not find main display."
+ exit 1
+fi
+
+echo "Set ${MAIN} as primary"
+xrandr --output ${MAIN} --auto --primary
+
+OTHER=$(xrandr | grep "\<connected\>" | grep -v eDP | cut -f1 -d" ")
+if [ "${OTHER}" = "" ]; then
+ echo "Could not find external display."
+ exit 1
+fi
+
+echo "Set ${OTHER} off"
+xrandr --output ${OTHER} --off