From 54966bd59da75595e7a65001568a4e6ac529fe16 Mon Sep 17 00:00:00 2001 From: Justin Oros Date: Wed, 12 Feb 2020 15:52:08 -0700 Subject: [PATCH] Add files via upload rotate screen clockwise in a circle --- rotate.sh | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 rotate.sh diff --git a/rotate.sh b/rotate.sh new file mode 100644 index 0000000..d72d0c0 --- /dev/null +++ b/rotate.sh @@ -0,0 +1,24 @@ +#!/bin/bash + +# rotate all screens clockwise once +# by Justin Oros +# revised FEB 12 2020 + +myScreenTypes="VGA HDMI DP eDP" +myScreenRotations="normal right inverted left normal" +myScreenNum=1 +mySleepTime=3 +myDisplay=:0 + +rotate() { +export DISPLAY=$myDisplay +for myScreenRotation in $myScreenRotations +do + for myScreenType in $myScreenTypes + do + xrandr --output $myScreenType-$myScreenNum --rotate $myScreenRotation > /dev/null 2>&1 + sleep $mySleepTime + done +done +} +rotate