Browse Source

Add script for querying banshee

coc
Schneider 8 years ago
parent
commit
1732dc5308
  1. 9
      tmux/banshee.sh
  2. 3
      tmux/theme.sh

9
tmux/banshee.sh

@ -0,0 +1,9 @@
#!/bin/bash
# Check if banshee exists
hash banshee 2>/dev/null || exit 1
ARTIST=$(banshee --query-artist | awk '{$1=""; print substr($0,2)}')
TITLE=$(banshee --query-title | awk '{$1=""; print substr($0,2)}')
echo "$TITLE - $ARTIST"

3
tmux/theme.sh

@ -51,6 +51,7 @@ set-window-option -g clock-mode-colour $tm_color_active
#tm_tunes="#[fg=$tm_color_music]#(osascript ~/.dotfiles/applescripts/tunes.scpt)" #tm_tunes="#[fg=$tm_color_music]#(osascript ~/.dotfiles/applescripts/tunes.scpt)"
#tm_battery="#(~/.dotfiles/bin/battery_indicator.sh)" #tm_battery="#(~/.dotfiles/bin/battery_indicator.sh)"
tm_banshee="#[fg=$tm_color_music]#($HOME/.dotfiles/tmux/banshee.sh)"
tm_battery="#[fg=$tm_color_inactive]#(upower -i /org/freedesktop/UPower/devices/battery_BAT0 | grep percentage | awk '{print $2}')" tm_battery="#[fg=$tm_color_inactive]#(upower -i /org/freedesktop/UPower/devices/battery_BAT0 | grep percentage | awk '{print $2}')"
tm_date="#[fg=$tm_color_inactive] %R %d %b" tm_date="#[fg=$tm_color_inactive] %R %d %b"
@ -58,4 +59,4 @@ tm_host="#[fg=$tm_color_feature,bold]#h"
tm_session_name="#[fg=$tm_color_feature,bold]$tm_icon #S" tm_session_name="#[fg=$tm_color_feature,bold]$tm_icon #S"
set -g status-left $tm_session_name' ' set -g status-left $tm_session_name' '
set -g status-right $tm_battery' '$tm_date' '$tm_host
set -g status-right $tm_banshee' '$tm_battery' '$tm_date' '$tm_host
Loading…
Cancel
Save