dotwryn/config/xserver/set_randr_layout

20 lines
367 B
Plaintext
Raw Normal View History

#!/bin/zsh
source $HOME/.my_zsh_env
2019-09-26 16:13:45 +00:00
XSERVER_DIR="$DOTWRYN/config/xserver"
2019-12-31 21:26:32 +00:00
AT_HOME(){
xrandr -q | grep -q 'HDMI-0 connected';
}
2019-12-31 21:26:32 +00:00
AT_RENT() {
xrandr -q | grep -q 'DP-[0134] connected';
}
2019-12-31 21:26:32 +00:00
if AT_HOME; then
"$XSERVER_DIR/screenlayout/homedock_hdmionly.sh";
2019-12-31 21:26:32 +00:00
elif AT_RENT; then
"$XSERVER_DIR/screenlayout/workdock.sh";
else;
"$XSERVER_DIR/screenlayout/undock.sh";
fi