Fixes multimonitor hyprworkspace script
This commit is contained in:
@@ -351,7 +351,7 @@
|
|||||||
activemonitor=$(grep -B 11 "focused: yes" "$monitors" | awk 'NR==1 {print $2}')
|
activemonitor=$(grep -B 11 "focused: yes" "$monitors" | awk 'NR==1 {print $2}')
|
||||||
passivemonitor=$(grep -B 6 "($workspace)" "$monitors" | awk 'NR==1 {print $2}')
|
passivemonitor=$(grep -B 6 "($workspace)" "$monitors" | awk 'NR==1 {print $2}')
|
||||||
#activews=$(grep -A 2 "$activemonitor" "$monitors" | awk 'NR==3 {print $1}' RS='(' FS=')')
|
#activews=$(grep -A 2 "$activemonitor" "$monitors" | awk 'NR==3 {print $1}' RS='(' FS=')')
|
||||||
passivews=$(grep -A 6 "Monitor $passivemonitor" "$monitors" | awk 'NR==4 {print $1}' RS='(' FS=')')
|
passivews=$(grep -A 6 "Monitor $passivemonitor" "$monitors" | awk 'NR==3 {print $1}' RS='(' FS=')')
|
||||||
|
|
||||||
if [[ $workspace -eq $passivews ]] && [[ $activemonitor != "$passivemonitor" ]]; then
|
if [[ $workspace -eq $passivews ]] && [[ $activemonitor != "$passivemonitor" ]]; then
|
||||||
hyprctl dispatch workspace "$workspace" && hyprctl dispatch swapactiveworkspaces "$activemonitor" "$passivemonitor" && hyprctl dispatch workspace "$workspace"
|
hyprctl dispatch workspace "$workspace" && hyprctl dispatch swapactiveworkspaces "$activemonitor" "$passivemonitor" && hyprctl dispatch workspace "$workspace"
|
||||||
|
Reference in New Issue
Block a user