Add truncation to sb-music
This commit is contained in:
parent
92dc97db10
commit
46cf2482fe
|
@ -18,7 +18,7 @@ if status="$(playerctl "$@" status 2>&1)" && [ "$status" != "Stopped" ]; then
|
|||
currentSong="$(playerctl "$@" metadata --format "{{title}} - {{artist}}")"
|
||||
else
|
||||
[ "$(mpc status "%state%")" = "paused" ] && icon="$pausedIcon"
|
||||
currentSong="$(mpc current -f "%title%")"
|
||||
currentSong="$(mpc current -f "%title%" | awk '{print substr($0, 1, 30) "..."}')"
|
||||
fi
|
||||
|
||||
[ -z "$currentSong" ] && exit
|
||||
|
|
Loading…
Reference in a new issue