This really should not take 19 minutes to build.

This commit is contained in:
coolnsx
2023-09-03 22:08:51 +05:30
parent b0f598bec3
commit 46a74bdbb5
3 changed files with 25 additions and 31 deletions

View File

@@ -4,7 +4,7 @@ out=$(printf '{ "command": ["get_property", "pause"]}\n' | socat - /tmp/mpvsocke
case $1 in
song)
if [ -n "$out" ] && pgrep -f mpvsocket >/dev/null 2>&1;then
cut -d'>' -f1 < "/tmp/yt-music/current" | cut -d':' -f2 | sed 's|[^-]*$||;s|-$||'
cut -d'>' -f1 < "/tmp/yt-music/current" | cut -d':' -f2 | sed 's|[^-]*$||;s|[-| ]$||'
else
printf "OFFLINE"
fi