Dotfiles/bin/.bin/screenlayouts/laptop-only.sh
Jonathan Hodgson cc94b994b5 Makes the screen layouts scripts slightly more robust
I should probably re-work all of them at some point but these changes
allow for external monitors with a resolution other than 1920x1080. When
switching to laptop only, I disable all other monitors by listing all
rather than hard coding common ones
2021-11-16 10:34:36 +00:00

5 lines
271 B
Bash
Executable file

#!/bin/sh
pkill compton
xrandr | sed '/^ /d' | grep -Ev '(:|eDP-1)' | awk -v ORS=" " '{print "--output " $1 " --off"}' |
xargs xrandr --output eDP-1 --primary --mode 1920x1080 --pos 0x0 --rotate normal
/usr/bin/compton --config "$HOME/.config/picom/picom.conf" & disown