blob: 6550d0d2e6fc9397c97d8784d43a2bdeb99b94b4 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
#!/bin/bash
player_name=$(playerctl metadata --format '{{playerName}}')
player_status=$(playerctl status)
if [[ "$player_status" == "Playing" ]]; then
if [[ "$player_name" == "spotify" ]]; then
song_info=$(playerctl metadata --format '{{title}} {{artist}}')
elif [[ "$player_name" == "firefox" ]]; then
song_info=$(playerctl metadata --format '{{title}} {{artist}}')
elif [[ "$player_name" == "mpd" ]]; then
song_info=$(playerctl metadata --format '{{title}} {{artist}}')
elif [[ "$player_name" == "chromium" ]]; then
song_info=$(playerctl metadata --format '{{title}} {{artist}}')
fi
fi
echo "$song_info"
|