Regenerated

This commit is contained in:
2026-04-11 16:13:02 +02:00
parent a64217bfee
commit f0326b3f40
8 changed files with 324 additions and 605 deletions
@@ -1,17 +0,0 @@
#!/usr/bin/env bash
bt_connected=""
while read -r _ mac name_rest; do
if [ "$(bluetoothctl info "$mac" | awk '/Connected:/ {print $2}')" = "yes" ]; then
bt_connected+="$name_rest\n"
fi
done < <(bluetoothctl devices)
# icon
if [ -n "$bt_connected" ]; then
icon=""
tooltip=$(printf "%b" "$bt_connected")
else
icon=""
tooltip="No devices connected"
fi
# ALWAYS produce valid JSON
printf '{"text": "%s", "tooltip": "%s"}\n' "$icon" "$tooltip"
@@ -1,35 +0,0 @@
#!/usr/bin/env bash
# Get focused monitor name
focused_monitor=$(hyprctl monitors -j | jq -r '.[] | select(.focused==true) | .name')
monitor="${WAYBAR_OUTPUT_NAME:-$focused_monitor}"
# Hide if not focused monitor
if [ "$monitor" != "$focused_monitor" ]; then
jq -c -n '{text:"", class:"hidden"}'
exit 0
fi
# Get active workspace on this monitor
active_ws=$(hyprctl monitors -j | jq -r \
".[] | select(.name==\"$monitor\") | .activeWorkspace.id")
# Get clients
clients=$(hyprctl clients -j | jq -r \
".[] | select(.workspace.id==$active_ws) | \"\(.title)\"")
count=$(echo "$clients" | grep -c '\S')
# 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
tooltip=$(echo "$clients" | sed 's/^/• /' | paste -sd '\n' -)
jq -c -n \
--arg text "$count" \
--arg tooltip "$tooltip" \
--arg class "active" \
'{text:$text, tooltip:$tooltip, class:$class}'
@@ -1,8 +0,0 @@
#!/usr/bin/env bash
active_ws=$(hyprctl activeworkspace -j | jq -r '.id')
clients=$(hyprctl clients -j | jq -r \
".[] | select(.workspace.id==$active_ws) | \"\(.address)|\(.title)\"")
choice=$(echo "$clients" | cut -d'|' -f2 | wofi -dmenu -j -p "Active apps" --style ~/.config/wofi/style.css)
[ -z "$choice" ] && exit 0
addr=$(echo "$clients" | grep "|$choice" | head -n1 | cut -d'|' -f1)
hyprctl dispatch focuswindow address:$addr