feat: starting nvidia manages external <-> internal montior

This commit is contained in:
Flinner Yuu 2022-07-14 13:51:32 +03:00
parent 84a5671e6d
commit 5f316de0e3
Signed by: flinner
GPG Key ID: 95CE0DA7F0E58CA6
1 changed files with 13 additions and 0 deletions

View File

@ -0,0 +1,13 @@
#!/bin/sh
intern=eDP-1-1
extern=HDMI-0
if xrandr | grep "$extern disconnected"; then
xrandr --output "$extern" --off --output "$intern" --auto
echo "External Monitor $extern is disconnected"
else
xrandr --output "$intern" --off --output "$extern" --auto
echo " External Monitor $extern is connected"
echo "So, Internal Monitor $intern was shutdown"
fi