Regenerated

This commit is contained in:
2026-04-11 15:27:38 +02:00
parent 78a635b865
commit 88a33b0f3e
3 changed files with 347 additions and 373 deletions
+329 -338
View File
File diff suppressed because it is too large Load Diff
+9 -18
View File
@@ -3575,48 +3575,39 @@ These are config files for waybar
#+BEGIN_SRC sh :tangle generated/.config/waybar/scripts/hypr-workspaces.sh :noweb yes :mkdirp yes :eval never
#!/usr/bin/env bash
# Debug: log what waybar passes
echo "WAYBAR_OUTPUT=$WAYBAR_OUTPUT" >> /tmp/waybar-debug.log
# Get focused monitor name
focused_monitor=$(hyprctl monitors -j | jq -r '.[] | select(.focused==true) | .name')
echo "focused_monitor=$focused_monitor" >> /tmp/waybar-debug.log
monitor="${WAYBAR_OUTPUT_NAME:-$focused_monitor}"
# Get the focused monitor name
focused_monitor=$(hyprctl monitors -j | jq -r '.[] | select(.focused==true) | .name')
# Hide if this bar's monitor is not the focused one
if [ "$WAYBAR_OUTPUT" != "$focused_monitor" ]; then
# Hide if not focused monitor
if [ "$monitor" != "$focused_monitor" ]; then
jq -c -n '{text:"", class:"hidden"}'
exit 0
fi
# Get active workspace ID on this monitor
# Get active workspace on this monitor
active_ws=$(hyprctl monitors -j | jq -r \
".[] | select(.name==\"$WAYBAR_OUTPUT\") | .activeWorkspace.id")
".[] | select(.name==\"$monitor\") | .activeWorkspace.id")
# Get clients in active workspace
# Get clients
clients=$(hyprctl clients -j | jq -r \
".[] | select(.workspace.id==$active_ws) | \"\(.title)\"")
# Count clients (only non-empty lines)
count=$(echo "$clients" | grep -c '\S')
# If no clients → hide module
if [ "$count" -eq 0 ]; then
# Hide if 0 or 1 clients — no point showing window switcher
if [ "$count" -le 1 ]; then
jq -c -n '{text:"", class:"hidden"}'
exit 0
fi
# Build tooltip
tooltip=$(echo "$clients" | sed 's/^/• /' | paste -sd '\n' -)
# Output JSON
jq -c -n \
--arg text "$count" \
--arg tooltip "$tooltip" \
--arg class "active" \
'{text:$text, tooltip:$tooltip, class:$class}'
#+END_SRC
** =generated/.config/waybar/scripts/hypr-workspacesmenu.sh=
@@ -1,41 +1,33 @@
#!/usr/bin/env bash
# Debug: log what waybar passes
echo "WAYBAR_OUTPUT=$WAYBAR_OUTPUT" >> /tmp/waybar-debug.log
# Get focused monitor name
focused_monitor=$(hyprctl monitors -j | jq -r '.[] | select(.focused==true) | .name')
echo "focused_monitor=$focused_monitor" >> /tmp/waybar-debug.log
monitor="${WAYBAR_OUTPUT_NAME:-$focused_monitor}"
# Get the focused monitor name
focused_monitor=$(hyprctl monitors -j | jq -r '.[] | select(.focused==true) | .name')
# Hide if this bar's monitor is not the focused one
if [ "$WAYBAR_OUTPUT" != "$focused_monitor" ]; then
# Hide if not focused monitor
if [ "$monitor" != "$focused_monitor" ]; then
jq -c -n '{text:"", class:"hidden"}'
exit 0
fi
# Get active workspace ID on this monitor
# Get active workspace on this monitor
active_ws=$(hyprctl monitors -j | jq -r \
".[] | select(.name==\"$WAYBAR_OUTPUT\") | .activeWorkspace.id")
".[] | select(.name==\"$monitor\") | .activeWorkspace.id")
# Get clients in active workspace
# Get clients
clients=$(hyprctl clients -j | jq -r \
".[] | select(.workspace.id==$active_ws) | \"\(.title)\"")
# Count clients (only non-empty lines)
count=$(echo "$clients" | grep -c '\S')
# If no clients → hide module
if [ "$count" -eq 0 ]; then
# Hide if 0 or 1 clients — no point showing window switcher
if [ "$count" -le 1 ]; then
jq -c -n '{text:"", class:"hidden"}'
exit 0
fi
# Build tooltip
tooltip=$(echo "$clients" | sed 's/^/• /' | paste -sd '\n' -)
# Output JSON
jq -c -n \
--arg text "$count" \
--arg tooltip "$tooltip" \