Added script that sets the primary monitor using xrandr.
This commit is contained in:
parent
ed1d0db617
commit
b8d9ff90aa
8
.config/scripts/sway/set-correct-monitor
Executable file
8
.config/scripts/sway/set-correct-monitor
Executable file
@ -0,0 +1,8 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
display=$(xrandr --listactivemonitors | grep "$1" | head -n1 | cut -d' ' -f6)
|
||||||
|
|
||||||
|
if [ -n "$display" ]; then
|
||||||
|
xrandr --output $display --primary
|
||||||
|
fi
|
||||||
|
|
Loading…
Reference in New Issue
Block a user