15 lines
210 B
Bash
15 lines
210 B
Bash
#!/bin/bash
|
|
|
|
playerstatus=$(playerctl status)
|
|
echo "$playerstatus"
|
|
if [[ "$playerstatus" = "Playing" ]]
|
|
then
|
|
playerctl -a stop
|
|
exit 0
|
|
fi
|
|
if [[ "$playerstatus" = "Stopped" ]]
|
|
then
|
|
playerctl play
|
|
exit 0
|
|
fi
|