Lets go
This commit is contained in:
parent
8425d4b953
commit
f7b659fdd9
21
toggle-xrandr
Executable file
21
toggle-xrandr
Executable file
@ -0,0 +1,21 @@
|
||||
#!/bin/sh
|
||||
|
||||
doIt() {
|
||||
if xrandr | grep 'HDMI-A-0' | grep connected >/dev/null; then
|
||||
xrandr --output HDMI-A-0 --set TearFree "$1"
|
||||
else
|
||||
xrandr --output eDP --set TearFree "on"
|
||||
fi
|
||||
}
|
||||
|
||||
case "$1" in
|
||||
"on")
|
||||
doIt "on"
|
||||
;;
|
||||
"off")
|
||||
doIt "off"
|
||||
;;
|
||||
*)
|
||||
echo "That option doesn't exist"
|
||||
;;
|
||||
esac
|
Loading…
Reference in New Issue
Block a user