handle disconnected monitors
This commit is contained in:
parent
115b3c31f8
commit
54a782f4d1
1 changed files with 3 additions and 2 deletions
|
@ -1,8 +1,9 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
LIST="$(xrandr | sed '/ connected/!d;s/ .*$//')"
|
LIST="$(xrandr | sed '/ connected/!d;s/ .*$//')"
|
||||||
MONITORS="$(printf '%s' "${LIST}" | tr '\n' ' ')"
|
|
||||||
MIRR="$(printf 'Yes\nNo' | menu "Mirror monitors?:")"
|
|
||||||
ULIST="$(xrandr | sed '/ disconnected/!d;s/ .*$//')"
|
ULIST="$(xrandr | sed '/ disconnected/!d;s/ .*$//')"
|
||||||
|
MONITORS="$(printf '%s' "${LIST}" | tr '\n' ' ')"
|
||||||
|
|
||||||
|
MIRR="$(printf 'Yes\nNo' | menu "Mirror monitors?:")"
|
||||||
|
|
||||||
for i in ${ULIST} ; do
|
for i in ${ULIST} ; do
|
||||||
UNSET="${UNSET} --output ${i} --off"
|
UNSET="${UNSET} --output ${i} --off"
|
||||||
|
|
Loading…
Reference in a new issue