Added mobile monitor setup scripts

This commit is contained in:
Wryn Wagner
2020-01-23 16:08:28 -07:00
parent fe57223828
commit e1a7870d5d
3 changed files with 42 additions and 0 deletions

View File

@ -1,4 +1,5 @@
#!/bin/sh
xrandr --output DP-0 --off\
--output DP-1 --off\
--output DP-3 --off\
@ -6,6 +7,14 @@ xrandr --output DP-0 --off\
--output DP-2 --primary --mode 2880x1800 --scale 0.8x0.8 --pos 0x0 --rotate normal\
--output HDMI-0 --pos 2880x0 --rotate normal
#xrandr | grep -q "3840" >/dev/null 2>&1;
#if [[ $? -ne 0 ]]; then
# if xrandr | grep -q "1920"; then
# xrandr --output HDMI-0 --mode 1920x1080 --pos 2880x0 --rotate normal --scale 1.5x1.5;
# fi
#fi
ROLL=$(($RANDOM%4));
if [ $ROLL -eq 0 ]; then

View File

@ -0,0 +1,22 @@
#!/bin/sh
if xrandr | grep -q "DP-0 connected"; then
xrandr \
--output DP-0 --mode 1920x1080 --pos 0x0 --rotate normal --scale 1.5x1.5 --primary\
--output DP-1 --off\
--output DP-2 --mode 2880x1800 --pos 5760x0 --rotate normal --scale 0.8x0.8\
--output DP-3 --off\
--output DP-4 --mode 1920x1080 --pos 2880x0 --rotate normal --scale 1.5x1.5\
--output HDMI-0 --mode 1920x1080 --pos 8640x0 --rotate left\
;
else
xrandr \
--output DP-0 --off\
--output DP-1 --mode 1920x1080 --pos 0x0 --rotate normal --scale 1.5x1.5 --primary\
--output DP-2 --mode 2880x1800 --pos 5760x0 --rotate normal --scale 0.8x0.8\
--output DP-3 --mode 1920x1080 --pos 2880x0 --rotate normal --scale 1.5x1.5\
--output DP-4 --off\
--output HDMI-0 --mode 1920x1080 --pos 8640x0 --rotate left\
;
fi
feh --bg-fill --randomize $HOME/Pictures/bg >/dev/null 2>&1;