Add Playerctl Modules

This commit is contained in:
Sravan Balaji
2024-09-29 23:39:58 -04:00
parent 7f7b4bc534
commit 0220b902bb
7 changed files with 299 additions and 4 deletions

View File

@@ -0,0 +1,10 @@
#!/usr/bin/env bash
mediaStatus=$(playerctl --player=playerctld metadata 2>&1)
if [[ "$mediaStatus" == "No player could handle this command" ]]; then
echo "N/A"
else
status=$(playerctl --player=playerctld metadata --format '{{ status }}')
echo $status
fi