summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorJulian T <julian@jtle.dk>2021-09-29 10:54:05 +0200
committerJulian T <julian@jtle.dk>2021-09-29 10:54:05 +0200
commit322110c2dd3d75b942b1122d0ac8f050e1015957 (patch)
tree8e3a5b6267c46c7877e542412973e3747eceeb28 /scripts
parent20f30dae896ade64585c475f28ec41f2ded6ecc6 (diff)
Add packages, other config and fix script
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/Scripts/xrotate9
1 files changed, 6 insertions, 3 deletions
diff --git a/scripts/Scripts/xrotate b/scripts/Scripts/xrotate
index fabe98b..5518df3 100755
--- a/scripts/Scripts/xrotate
+++ b/scripts/Scripts/xrotate
@@ -11,9 +11,6 @@ function help() {
echo " -h, --help this help message"
}
-# Fix hardcode
-DISP=LVDS1
-
BINNAME="xrotate"
# Parse some args
@@ -39,6 +36,12 @@ while [[ $# -gt 0 ]]; do
esac
done
+if [ -z "${DISP}" ]; then
+ # TODO, this will break with more displays
+ DISP=$(xrandr | awk -F ' ' '/ connected/ {print $1}')
+fi
+
+
O=$1
MOUSE=$(xinput list | grep "slave pointer" | awk '{print $6}' | awk -F '=' '{print $2}')