mirror of
https://github.com/lordmathis/dotfiles.git
synced 2025-11-06 09:44:25 +00:00
Housekeeping
This commit is contained in:
21
bin/xrandr/switch_monitors.sh
Executable file
21
bin/xrandr/switch_monitors.sh
Executable file
@@ -0,0 +1,21 @@
|
||||
#!/bin/bash
|
||||
|
||||
intern=eDP-1
|
||||
extern=HDMI-1
|
||||
|
||||
case $1 in
|
||||
"-i")
|
||||
m=$intern
|
||||
;;
|
||||
"-e")
|
||||
m=$extern
|
||||
;;
|
||||
*)
|
||||
echo "Wrong option"
|
||||
esac
|
||||
|
||||
if xrandr --listactivemonitors | grep "$m"; then
|
||||
xrandr --output "$m" --off
|
||||
else
|
||||
xrandr --output "$m" --auto
|
||||
fi
|
||||
Reference in New Issue
Block a user