2
# Banshee Emulated pipe
3
# Pipe created by ChAnGFu
6
STATUS=$(banshee --query-status)
9
if [ "$STATUS" -eq "-1" ]; then
13
TITLE=$(banshee --query-title)
14
ARTIST=$(banshee --query-artist)
15
GTITLE="${ARTIST#*:} -${TITLE#*:}"
16
TTIMESEC=$(banshee --query-duration)
17
TTIMESEC=${TTIMESEC#*:}
18
POSITIONSEC=$(banshee --query-position)
19
POSITIONSEC=${POSITIONSEC#*:}
25
M=$(($POSITIONSEC/60))
26
S=$(($POSITIONSEC%60))
30
if [ "$STATUS" -eq "1" ]; then
31
echo "status: Playing"
32
elif [ "$STATUS" -eq "0" ]; then
36
echo "trackInPlaylist: N/A"
37
#Position actuelle en secondes
38
echo "uSecPosition: $POSITIONSEC"
40
#echo "timeElapsed $ETIME"
42
#Temps total en secondes
43
echo "totalTimeInSec $TTIMESEC"
45
#echo "totalTime: $TTIME"
48
echo "nowTitle: $GTITLE"