diff --git a/eww_desktop/scripts/workspace b/eww_desktop/scripts/workspace index 92d2201..a42ec58 100755 --- a/eww_desktop/scripts/workspace +++ b/eww_desktop/scripts/workspace @@ -1,14 +1,16 @@ #!/bin/bash workspaces() { -ws1="ID 1" -ws2="ID 2" -ws3="ID 3" -ws4="ID 4" -ws5="ID 5" -ws6="ID 6" -ws7="ID 7" -ws8="ID 8" +ws1="ID 1 " +ws2="ID 2 " +ws3="ID 3 " +ws4="ID 4 " +ws5="ID 5 " +ws6="ID 6 " +ws7="ID 7 " +ws8="ID 8 " +ws9="ID 9 " +ws0="ID 10" # check if Occupied o1=$(hyprctl workspaces | grep "$ws1" ) @@ -19,16 +21,20 @@ o5=$(hyprctl workspaces | grep "$ws5" ) o6=$(hyprctl workspaces | grep "$ws6" ) o7=$(hyprctl workspaces | grep "$ws7" ) o8=$(hyprctl workspaces | grep "$ws8" ) +o9=$(hyprctl workspaces | grep "$ws9" ) +o0=$(hyprctl workspaces | grep "$ws0" ) # check if Focused -f1=$(hyprctl monitors | grep "workspace: 1" -A 4 | grep "focused: yes" ) -f2=$(hyprctl monitors | grep "workspace: 2" -A 4 | grep "focused: yes" ) -f3=$(hyprctl monitors | grep "workspace: 3" -A 4 | grep "focused: yes" ) -f4=$(hyprctl monitors | grep "workspace: 4" -A 4 | grep "focused: yes" ) -f5=$(hyprctl monitors | grep "workspace: 5" -A 4 | grep "focused: yes" ) -f6=$(hyprctl monitors | grep "workspace: 6" -A 4 | grep "focused: yes" ) -f7=$(hyprctl monitors | grep "workspace: 7" -A 4 | grep "focused: yes" ) -f8=$(hyprctl monitors | grep "workspace: 8" -A 4 | grep "focused: yes" ) +f1=$(hyprctl monitors | grep "workspace: 1 " -A 4 | grep "focused: yes" ) +f2=$(hyprctl monitors | grep "workspace: 2 " -A 4 | grep "focused: yes" ) +f3=$(hyprctl monitors | grep "workspace: 3 " -A 4 | grep "focused: yes" ) +f4=$(hyprctl monitors | grep "workspace: 4 " -A 4 | grep "focused: yes" ) +f5=$(hyprctl monitors | grep "workspace: 5 " -A 4 | grep "focused: yes" ) +f6=$(hyprctl monitors | grep "workspace: 6 " -A 4 | grep "focused: yes" ) +f7=$(hyprctl monitors | grep "workspace: 7 " -A 4 | grep "focused: yes" ) +f8=$(hyprctl monitors | grep "workspace: 8 " -A 4 | grep "focused: yes" ) +f9=$(hyprctl monitors | grep "workspace: 9 " -A 4 | grep "focused: yes" ) +f0=$(hyprctl monitors | grep "workspace: 10" -A 4 | grep "focused: yes" ) if [ "$o1" != "" ]; then ic_1="①" @@ -70,6 +76,16 @@ if [ "$o8" != "" ]; then else ic_8="" fi +if [ "$o9" != "" ]; then + ic_9="⑨" + else + ic_9="" +fi +if [ "$o0" != "" ]; then + ic_0="⑩" + else + ic_0="" +fi if [ "$f1" != "" ]; then ic_1="➊" @@ -87,11 +103,16 @@ elif [ "$f7" != "" ]; then ic_7="➐" elif [ "$f8" != "" ]; then ic_8="➑" +elif [ "$f9" != "" ]; then + ic_9="➒" +elif [ "$f0" != "" ]; then + ic_0="➓" fi + #ic_1=$(hyprctl workspaces) #ic_2="t" -echo "(box :class \"works\" :orientation \"h\" :spacing 5 :space-evenly \"false\" (button :onclick \"hyprctl dispatch workspace 1\" :class \"$un$o1$f1\" \"$ic_1\") (button :onclick \"hyprctl dispatch workspace 2\" :class \"$un$o2$f2\" \"$ic_2\") (button :onclick \"hyprctl dispatch workspace 3\" :class \"$un$o3$f3\" \"$ic_3\") (button :onclick \"hyprctl dispatch workspace 4\" :class \"$un$o4$f4\" \"$ic_4\") (button :onclick \"hyprctl dispatch workspace 5\" :class \"$un$o5$f5\" \"$ic_5\") (button :onclick \"hyprctl dispatch workspace 6\" :class \"$un$o6$f6\" \"$ic_6\") (button :onclick \"hyprctl dispatch workspace 7\" :class \"$un$o7$f7\" \"$ic_7\") (button :onclick \"hyprctl dispatch workspace 8\" :class \"$un$o8$f8\" \"$ic_8\"))" +echo "(box :class \"works\" :orientation \"h\" :spacing 5 :space-evenly \"false\" (button :onclick \"hyprctl dispatch workspace 1\" :class \"$un$o1$f1\" \"$ic_1\") (button :onclick \"hyprctl dispatch workspace 2\" :class \"$un$o2$f2\" \"$ic_2\") (button :onclick \"hyprctl dispatch workspace 3\" :class \"$un$o3$f3\" \"$ic_3\") (button :onclick \"hyprctl dispatch workspace 4\" :class \"$un$o4$f4\" \"$ic_4\") (button :onclick \"hyprctl dispatch workspace 5\" :class \"$un$o5$f5\" \"$ic_5\") (button :onclick \"hyprctl dispatch workspace 6\" :class \"$un$o6$f6\" \"$ic_6\") (button :onclick \"hyprctl dispatch workspace 7\" :class \"$un$o7$f7\" \"$ic_7\") (button :onclick \"hyprctl dispatch workspace 8\" :class \"$un$o8$f8\" \"$ic_8\") (button :onclick \"hyprctl dispatch workspace 9\" :class \"$un$o9$f9\" \"$ic_9\") (button :onclick \"hyprctl dispatch workspace 10\" :class \"$un$o0$f0\" \"$ic_0\"))" } workspaces tail -f /tmp/hypr/$HYPRLAND_INSTANCE_SIGNATURE/hyprland.log | grep -E --line-buffered "Changed to workspace|focus to surface" | while read -r; do diff --git a/eww_laptop/scripts/workspace b/eww_laptop/scripts/workspace index fd4b76b..a42ec58 100755 --- a/eww_laptop/scripts/workspace +++ b/eww_laptop/scripts/workspace @@ -10,7 +10,7 @@ ws6="ID 6 " ws7="ID 7 " ws8="ID 8 " ws9="ID 9 " -ws10="ID 10 " +ws0="ID 10" # check if Occupied o1=$(hyprctl workspaces | grep "$ws1" ) @@ -22,19 +22,19 @@ o6=$(hyprctl workspaces | grep "$ws6" ) o7=$(hyprctl workspaces | grep "$ws7" ) o8=$(hyprctl workspaces | grep "$ws8" ) o9=$(hyprctl workspaces | grep "$ws9" ) -o10=$(hyprctl workspaces | grep "$ws10" ) +o0=$(hyprctl workspaces | grep "$ws0" ) # check if Focused -f1=$(hyprctl monitors | grep "workspace: 1 " ) -f2=$(hyprctl monitors | grep "workspace: 2 " ) -f3=$(hyprctl monitors | grep "workspace: 3 " ) -f4=$(hyprctl monitors | grep "workspace: 4 " ) -f5=$(hyprctl monitors | grep "workspace: 5 " ) -f6=$(hyprctl monitors | grep "workspace: 6 " ) -f7=$(hyprctl monitors | grep "workspace: 7 " ) -f8=$(hyprctl monitors | grep "workspace: 8 " ) -f9=$(hyprctl monitors | grep "workspace: 9 " ) -f10=$(hyprctl monitors | grep "workspace: 10 " ) +f1=$(hyprctl monitors | grep "workspace: 1 " -A 4 | grep "focused: yes" ) +f2=$(hyprctl monitors | grep "workspace: 2 " -A 4 | grep "focused: yes" ) +f3=$(hyprctl monitors | grep "workspace: 3 " -A 4 | grep "focused: yes" ) +f4=$(hyprctl monitors | grep "workspace: 4 " -A 4 | grep "focused: yes" ) +f5=$(hyprctl monitors | grep "workspace: 5 " -A 4 | grep "focused: yes" ) +f6=$(hyprctl monitors | grep "workspace: 6 " -A 4 | grep "focused: yes" ) +f7=$(hyprctl monitors | grep "workspace: 7 " -A 4 | grep "focused: yes" ) +f8=$(hyprctl monitors | grep "workspace: 8 " -A 4 | grep "focused: yes" ) +f9=$(hyprctl monitors | grep "workspace: 9 " -A 4 | grep "focused: yes" ) +f0=$(hyprctl monitors | grep "workspace: 10" -A 4 | grep "focused: yes" ) if [ "$o1" != "" ]; then ic_1="①" @@ -77,14 +77,14 @@ if [ "$o8" != "" ]; then ic_8="" fi if [ "$o9" != "" ]; then - ic_9="➈" + ic_9="⑨" else ic_9="" fi -if [ "$o10" != "" ]; then - ic_10="➉" +if [ "$o0" != "" ]; then + ic_0="⑩" else - ic_10="" + ic_0="" fi if [ "$f1" != "" ]; then @@ -105,13 +105,14 @@ elif [ "$f8" != "" ]; then ic_8="➑" elif [ "$f9" != "" ]; then ic_9="➒" -elif [ "$f10" != "" ]; then - ic_10="➓" +elif [ "$f0" != "" ]; then + ic_0="➓" fi + #ic_1=$(hyprctl workspaces) #ic_2="t" -echo "(box :class \"works\" :orientation \"h\" :spacing 5 :space-evenly \"false\" (button :onclick \"hyprctl dispatch workspace 1\" :class \"$un$o1$f1\" \"$ic_1\") (button :onclick \"hyprctl dispatch workspace 2\" :class \"$un$o2$f2\" \"$ic_2\") (button :onclick \"hyprctl dispatch workspace 3\" :class \"$un$o3$f3\" \"$ic_3\") (button :onclick \"hyprctl dispatch workspace 4\" :class \"$un$o4$f4\" \"$ic_4\") (button :onclick \"hyprctl dispatch workspace 5\" :class \"$un$o5$f5\" \"$ic_5\") (button :onclick \"hyprctl dispatch workspace 6\" :class \"$un$o6$f6\" \"$ic_6\") (button :onclick \"hyprctl dispatch workspace 7\" :class \"$un$o7$f7\" \"$ic_7\") (button :onclick \"hyprctl dispatch workspace 8\" :class \"$un$o8$f8\" \"$ic_8\") (button :onclick \"hyprctl dispatch workspace 9\" :class \"$un$o9$f9\" \"$ic_9\") (button :onclick \"hyprctl dispatch workspace 10\" :class \"$un$o10$f10\" \"$ic_10\"))" +echo "(box :class \"works\" :orientation \"h\" :spacing 5 :space-evenly \"false\" (button :onclick \"hyprctl dispatch workspace 1\" :class \"$un$o1$f1\" \"$ic_1\") (button :onclick \"hyprctl dispatch workspace 2\" :class \"$un$o2$f2\" \"$ic_2\") (button :onclick \"hyprctl dispatch workspace 3\" :class \"$un$o3$f3\" \"$ic_3\") (button :onclick \"hyprctl dispatch workspace 4\" :class \"$un$o4$f4\" \"$ic_4\") (button :onclick \"hyprctl dispatch workspace 5\" :class \"$un$o5$f5\" \"$ic_5\") (button :onclick \"hyprctl dispatch workspace 6\" :class \"$un$o6$f6\" \"$ic_6\") (button :onclick \"hyprctl dispatch workspace 7\" :class \"$un$o7$f7\" \"$ic_7\") (button :onclick \"hyprctl dispatch workspace 8\" :class \"$un$o8$f8\" \"$ic_8\") (button :onclick \"hyprctl dispatch workspace 9\" :class \"$un$o9$f9\" \"$ic_9\") (button :onclick \"hyprctl dispatch workspace 10\" :class \"$un$o0$f0\" \"$ic_0\"))" } workspaces tail -f /tmp/hypr/$HYPRLAND_INSTANCE_SIGNATURE/hyprland.log | grep -E --line-buffered "Changed to workspace|focus to surface" | while read -r; do