summaryrefslogtreecommitdiff
path: root/config/scripts/radioinfo-1113-1030
diff options
context:
space:
mode:
Diffstat (limited to 'config/scripts/radioinfo-1113-1030')
-rwxr-xr-xconfig/scripts/radioinfo-1113-103024
1 files changed, 24 insertions, 0 deletions
diff --git a/config/scripts/radioinfo-1113-1030 b/config/scripts/radioinfo-1113-1030
new file mode 100755
index 0000000..25e5de5
--- /dev/null
+++ b/config/scripts/radioinfo-1113-1030
@@ -0,0 +1,24 @@
+#!/bin/bash
+# PlanetRadio-Playlist
+# $1 = outfile
+
+### Variabel
+Name="planet radio [www.planetradio.de]"
+###
+
+# get...
+wget -q --tries=1 --timeout=10 -O /tmp/playlist "http://www.planetradio.de/p_mt.php"
+
+# Artist/Title
+all=`grep -A1 'die letzten 3 tracks' /tmp/playlist`
+title=${all/*$'<table><tr><td>'????????????????????/}; title=${title/$'<'\/'td>'*/}
+artist=${all//*$'td><td>'/}; artist=${artist/$'<'\/'td>'*/}
+
+# write...
+if [ $1 ]; then
+ echo $Name > $1
+ echo $artist >> $1
+ echo $title >> $1
+else
+ echo "$Name: Interpret/Titel = $artist / $title"
+fi