2017-06-13 17:52:17 +03:00
|
|
|
#!/usr/bin/env zsh
|
2017-06-13 18:03:08 +03:00
|
|
|
if [[ -r $HOME/.displayrc ]]; then
|
|
|
|
. $HOME/.displayrc
|
|
|
|
else
|
|
|
|
exit 1
|
|
|
|
fi
|
|
|
|
|
2017-06-14 19:12:54 +03:00
|
|
|
variants=('int' 'ext' 'both')
|
|
|
|
selection=$(printf "%s\n" $variants|/usr/bin/dmenu -p display "$@")
|
2017-06-13 17:52:17 +03:00
|
|
|
case $selection in
|
2017-06-14 19:12:54 +03:00
|
|
|
($variants[1]) /usr/bin/xrandr --output $DISPLAY2 --off --output $DISPLAY1 --auto ;;
|
|
|
|
($variants[2]) /usr/bin/xrandr --output $DISPLAY1 --off --output $DISPLAY2 --auto ;;
|
|
|
|
($variants[3]) /usr/bin/xrandr --output $DISPLAY1 --auto --output $DISPLAY2 --auto --right-of $DISPLAY1 ;;
|
|
|
|
(*) exit 1 ;;
|
2017-06-13 17:52:17 +03:00
|
|
|
esac
|
2017-06-14 19:12:54 +03:00
|
|
|
/usr/bin/feh --bg-scale $HOME/.wallpaper.png
|
|
|
|
/usr/bin/sleep 1
|
2017-06-13 17:52:17 +03:00
|
|
|
exit 0
|