diff options
author | Julian T <julian@jtle.dk> | 2021-09-29 10:54:05 +0200 |
---|---|---|
committer | Julian T <julian@jtle.dk> | 2021-09-29 10:54:05 +0200 |
commit | 322110c2dd3d75b942b1122d0ac8f050e1015957 (patch) | |
tree | 8e3a5b6267c46c7877e542412973e3747eceeb28 /scripts/Scripts | |
parent | 20f30dae896ade64585c475f28ec41f2ded6ecc6 (diff) |
Add packages, other config and fix script
Diffstat (limited to 'scripts/Scripts')
-rwxr-xr-x | scripts/Scripts/xrotate | 9 |
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}') |