vincentbernat.i3wm-configur.../bin/spotify-clean
Vincent Bernat 8235201167 Revert "music: replace Spotify by Deezer"
This reverts commit 7086a909cf.
2024-05-18 14:42:40 +02:00

9 lines
322 B
Bash
Executable file

#!/bin/sh
# Kill all spotify streams, except the most recent one. We need to use
# the serial to know which one this is as ID are not monotonous.
pw-dump \
| jq '.[]|select(.type == "PipeWire:Interface:Client" and .info.props."application.name" == "spotify").id' \
| head -n-1 \
| xargs -trn1 pw-cli destroy