custom-hypr - add config hypr

This commit is contained in:
huyjaky
2024-10-21 16:52:57 +07:00
parent 3d18770151
commit 0cf0beb8c7
28 changed files with 1420 additions and 400 deletions

View File

@@ -0,0 +1,20 @@
#!/bin/bash
current_monitor=$(hyprctl activewindow | grep 'monitor' | awk '{print $2}')
export PRIMARY_MONITOR_WORKSPACE=$((PRIMARY_MONITOR_WORKSPACE+2))
export SECONDARY_MONITOR_WORKSPACE=$((SECONDARY_MONITOR_WORKSPACE+2))
if [ "$PRIMARY_MONITOR_WORKSPACE" -lt 1 ]; then
export PRIMARY_MONITOR_WORKSPACE=1
exit 1
elif [ "$SECONDARY_MONITOR_WORKSPACE" -gt 10 ]; then
export SECONDARY_MONITOR_WORKSPACE=10
exit 1
fi
hyprctl dispatch focusmonitor 0
hyprctl dispatch workspace $PRIMARY_MONITOR_WORKSPACE
hyprctl dispatch focusmonitor 1
hyprctl dispatch workspace $SECONDARY_MONITOR_WORKSPACE
hyprctl dispatch focusmonitor $current_monitor