diff options
| author | pants <niklasjo2004@gmail.com> | 2026-09-21 14:17:03 -0700 |
|---|---|---|
| committer | pants <niklasjo2004@gmail.com> | 2026-09-21 14:17:03 -0700 |
| commit | 7b21727285e50b0b050c4ddd70d07542229c5366 (patch) | |
| tree | 5d369153c5df5b41f3750d25479a68f20169c8ff /scripts/st-dbus-mon | |
init
Diffstat (limited to 'scripts/st-dbus-mon')
| -rwxr-xr-x | scripts/st-dbus-mon | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/scripts/st-dbus-mon b/scripts/st-dbus-mon new file mode 100755 index 0000000..5d325c7 --- /dev/null +++ b/scripts/st-dbus-mon @@ -0,0 +1,9 @@ +#!/bin/sh +dbus-monitor --session "member='PropertiesChanged'" | +while read X; do + if [[ $X == *"Metadata"* ]]; then + TITLE=$(playerctl metadata title) + ARTIST=$(playerctl metadata artist) + notify-send "Now playing" "$TITLE - $ARTIST" -i : + fi +done |
