diff options
Diffstat (limited to 'bin/.local')
| -rwxr-xr-x | bin/.local/bin/scripts/status/internet | 2 | ||||
| -rwxr-xr-x | bin/.local/bin/scripts/status/memory | 2 | ||||
| -rwxr-xr-x | bin/.local/bin/scripts/status/music | 9 | ||||
| -rwxr-xr-x | bin/.local/bin/scripts/status/time-clock | 4 | ||||
| -rwxr-xr-x | bin/.local/bin/scripts/status/weather | 2 |
5 files changed, 11 insertions, 8 deletions
diff --git a/bin/.local/bin/scripts/status/internet b/bin/.local/bin/scripts/status/internet index 6d0c513..5214193 100755 --- a/bin/.local/bin/scripts/status/internet +++ b/bin/.local/bin/scripts/status/internet @@ -5,7 +5,7 @@ # Show 🔒 if a vpn connection is active case $BLOCK_BUTTON in - 1) "$TERMINAL" -e nmtui; pkill -RTMIN+4 dwmblocks ;; + 1) "$TERMINAL" -c "floatterm" -n "floatterm" -g "150x35" -e nmtui; pkill -RTMIN+4 dwmblocks ;; 3) notify-send "🌐 Internet module" "\- Click to connect ❌: wifi disabled 📡: no wifi connection diff --git a/bin/.local/bin/scripts/status/memory b/bin/.local/bin/scripts/status/memory index 6c19de6..77fb96b 100755 --- a/bin/.local/bin/scripts/status/memory +++ b/bin/.local/bin/scripts/status/memory @@ -2,7 +2,7 @@ case $BLOCK_BUTTON in 1) notify-send "🧠 Memory hogs" "$(ps axch -o cmd:15,%mem --sort=-%mem | head)" ;; - 2) setsid -f "$TERMINAL" -e btop ;; + 2) setsid -f "$TERMINAL" -g "150x35" -c "floatterm" -n "floatterm" -e btop ;; 3) notify-send "🧠 Memory module" "\- Shows Memory Used/Total. - Click to show memory hogs. - Middle click to open htop." ;; diff --git a/bin/.local/bin/scripts/status/music b/bin/.local/bin/scripts/status/music index f59da89..5bc2e43 100755 --- a/bin/.local/bin/scripts/status/music +++ b/bin/.local/bin/scripts/status/music @@ -3,7 +3,7 @@ # Music module script for dwmblocks truncate() { - echo "$1" | cut -c1-20 + echo "$1" | cut -c1-15 } # Handle mouse events based on button clicks @@ -28,8 +28,8 @@ case $BLOCK_BUTTON in esac # Get current track info -artist="$(playerctl metadata artist 2>/dev/null || echo "Unknown Artist")" -title="$(playerctl metadata title 2>/dev/null || echo "No Track")" +artist="$(playerctl metadata artist 2>/dev/null || echo "none")" +title="$(playerctl metadata title 2>/dev/null || echo "none")" # Truncate artist and title to 15 characters truncated_artist=$(truncate "$artist") @@ -38,5 +38,6 @@ truncated_title=$(truncate "$title") # Format the output as "artist - title" current_track="$truncated_artist - $truncated_title" +icon="🎵" # Print the current track -echo "$current_track" +echo "$icon $current_track" diff --git a/bin/.local/bin/scripts/status/time-clock b/bin/.local/bin/scripts/status/time-clock index 70aff35..1e9adfb 100755 --- a/bin/.local/bin/scripts/status/time-clock +++ b/bin/.local/bin/scripts/status/time-clock @@ -18,6 +18,8 @@ case "$clock" in "12") icon="🕛" ;; esac +calendar_icon="📅" + case $BLOCK_BUTTON in 1) emacs-launcher "agenda" ;; 2) emacs-launcher "calendar" ;; @@ -25,4 +27,4 @@ case $BLOCK_BUTTON in - Middle click opens Emacs calendar" ;; esac -date "+%Y-%m-%d (%a) | $icon %R:%S %p " +date "+$calendar_icon %Y-%m-%d (%a) | $icon %R:%S " diff --git a/bin/.local/bin/scripts/status/weather b/bin/.local/bin/scripts/status/weather index 3d31aa9..eae0fec 100755 --- a/bin/.local/bin/scripts/status/weather +++ b/bin/.local/bin/scripts/status/weather @@ -39,7 +39,7 @@ showweather() { } case $BLOCK_BUTTON in - 1) setsid -f "$TERMINAL" -n "floatterm" -g "150x35" -e less -Sfr "$weatherreport" ;; + 1) setsid -f "$TERMINAL" -n "floatterm" -c "floatterm" -g "150x35" -e less -Sfr "$weatherreport" ;; 2) getforecast && showweather ;; 3) notify-send "🌈 Weather module" "\- Left click for full forecast. - Middle click to update forecast. |
