bspwm: Populate the primary monitor first

I'm so sorry for this
This commit is contained in:
Salt 2018-07-31 19:52:44 -05:00
parent 10d0dd2733
commit 36c39f9b94

View File

@ -34,7 +34,7 @@ desktops=8
deskpermon=$(expr $desktops / $monitors)
i=1
printf " [INFO] Putting $desktops desktops across $monitors monitors, $deskpermon each\n"
for monitor in $(bspc query -M); do
for monitor in $(xrandr -q | awk '/primary/{print $1}' && xrandr -q | grep ' connected' | grep -v 'primary' | awk '{print $1}'); do
until [[ "$(expr $i % \( $deskpermon + 1 \))" == "0" ]]; do
layout="$layout $i"
i=$(expr $i + 1)