✨ feat(music-stats): improve stats format and add additional metadata
Improves the shortening function. Adds loop, shuffle, and volume metadata. Uses better seperator characters to improve reliability.
This commit is contained in:
@@ -1,6 +1,9 @@
|
||||
#!/bin/bash
|
||||
# Separator variable
|
||||
separator="␟"
|
||||
|
||||
# Update the cache file every second
|
||||
while true; do
|
||||
playerctl --ignore-player firefox,kdeconnect,plasma-browser-integration metadata --format '{{ artist }} - {{ title }} - {{ album }} - {{ status }}' >~/.cache/music_cache.txt
|
||||
playerctl --ignore-player firefox,kdeconnect,haruna,plasma-browser-integration metadata --format "{{ artist }}${separator}{{ title }}${separator}{{ album }}${separator}{{ status }}${separator}{{ volume }}${separator}{{ loop }}${separator}{{ shuffle }}" >~/.cache/music_cache.txt
|
||||
sleep 1
|
||||
done
|
||||
|
||||
Reference in New Issue
Block a user