summaryrefslogtreecommitdiffstats
path: root/abs/extra/mythappletrailers/gen_trailer_menu.sh
diff options
context:
space:
mode:
authorBritney Fransen <brfransen@gmail.com>2018-09-05 15:51:59 (GMT)
committerBritney Fransen <brfransen@gmail.com>2018-09-05 15:51:59 (GMT)
commit89ac93c209dd138359e9a9e761d53042aea61e11 (patch)
treeb12a042d8f708c73f55e239a2dd4ad16bc4e3a72 /abs/extra/mythappletrailers/gen_trailer_menu.sh
parent7983ca5c37091f4d0ff33584fe9e2f4487400caa (diff)
downloadlinhes_pkgbuild-89ac93c209dd138359e9a9e761d53042aea61e11.zip
linhes_pkgbuild-89ac93c209dd138359e9a9e761d53042aea61e11.tar.gz
linhes_pkgbuild-89ac93c209dd138359e9a9e761d53042aea61e11.tar.bz2
mythappletrailers: update for php7 and url change. closes #1026
adjust loading.sh to wait for cache to fill then close
Diffstat (limited to 'abs/extra/mythappletrailers/gen_trailer_menu.sh')
-rw-r--r--abs/extra/mythappletrailers/gen_trailer_menu.sh39
1 files changed, 21 insertions, 18 deletions
diff --git a/abs/extra/mythappletrailers/gen_trailer_menu.sh b/abs/extra/mythappletrailers/gen_trailer_menu.sh
index 43b2fae..fabf0e0 100644
--- a/abs/extra/mythappletrailers/gen_trailer_menu.sh
+++ b/abs/extra/mythappletrailers/gen_trailer_menu.sh
@@ -4,26 +4,29 @@ sed -n -e 's/.*<action>\(.*\)<\/action>.*/\1/p' /tmp/appletrailer.xml > /tmp/a.l
awk < /tmp/a.log '{ print $NF }' > /tmp/b.log
sort -R /tmp/b.log > /tmp/c.log
echo "<mythmenu name=\"TRAILERS\">" > /tmp/appletrailer.2.xml
-echo " <button>" >> /tmp/appletrailer.2.xml
-echo " <type>VIDEO_BROWSER</type>" >> /tmp/appletrailer.2.xml
-echo " <text>Play All Trailers</text>" >> /tmp/appletrailer.2.xml
-echo " <action>EXEC /usr/bin/play_trailer.sh /home/mythtv/all_trailers</action>" >> /tmp/appletrailer.2.xml
-echo " </button>" >> /tmp/appletrailer.2.xml
+echo " <button>" >> /tmp/appletrailer.2.xml
+echo " <type>VIDEO_BROWSER</type>" >> /tmp/appletrailer.2.xml
+echo " <text>Play Random Trailer</text>" >> /tmp/appletrailer.2.xml
+echo " <action>EXEC loading.sh &amp; mplayer-wrapper.pl -fs -zoom -user-agent "QuickTime/7.6.2" -cache 16000 \$(sort -R /home/mythtv/apple_all_trailers | tail -1)</action>" >> /tmp/appletrailer.2.xml
+echo " </button>" >> /tmp/appletrailer.2.xml
echo "" >> /tmp/appletrailer.2.xml
-echo " <button>" >> /tmp/appletrailer.2.xml
-echo " <type>VIDEO_BROWSER</type>" >> /tmp/appletrailer.2.xml
-echo " <text>Shuffle Play Trailers</text>" >> /tmp/appletrailer.2.xml
-echo " <action>EXEC /usr/bin/play_trailer.sh /home/mythtv/shuffle_trailers</action>" >> /tmp/appletrailer.2.xml
+
+grep -v mythmenu /tmp/appletrailer.xml >> /tmp/appletrailer.2.xml
+
+echo " <button>" >> /tmp/appletrailer.2.xml
+echo " <type>VIDEO_BROWSER</type>" >> /tmp/appletrailer.2.xml
+echo " <text>Play All Trailers</text>" >> /tmp/appletrailer.2.xml
+echo " <action>EXEC play_trailer.sh /home/mythtv/apple_all_trailers</action>" >> /tmp/appletrailer.2.xml
echo " </button>" >> /tmp/appletrailer.2.xml
echo "" >> /tmp/appletrailer.2.xml
-echo " <button>" >> /tmp/appletrailer.2.xml
-echo " <type>VIDEO_BROWSER</type>" >> /tmp/appletrailer.2.xml
-echo " <text>Play Random Trailer</text>" >> /tmp/appletrailer.2.xml
-echo " <action>EXEC loading.sh &amp;&amp; mplayer -fs -zoom -really-quiet -user-agent "QuickTime/7.6.2" -cache 16000 \$(sort -R /home/mythtv/all_trailers | tail -1)</action>" >> /tmp/appletrailer.2.xml
-echo " </button>" >> /tmp/appletrailer.2.xml
+echo " <button>" >> /tmp/appletrailer.2.xml
+echo " <type>VIDEO_BROWSER</type>" >> /tmp/appletrailer.2.xml
+echo " <text>Shuffle All Trailers</text>" >> /tmp/appletrailer.2.xml
+echo " <action>EXEC play_trailer.sh /home/mythtv/apple_shuffle_trailers</action>" >> /tmp/appletrailer.2.xml
+echo " </button>" >> /tmp/appletrailer.2.xml
+echo "</mythmenu>" >> /tmp/appletrailer.2.xml
echo "" >> /tmp/appletrailer.2.xml
-
-grep -v TRAILERS /tmp/appletrailer.xml >> /tmp/appletrailer.2.xml
-mv /tmp/b.log /home/mythtv/all_trailers
-mv /tmp/c.log /home/mythtv/shuffle_trailers
+mv /tmp/b.log /home/mythtv/apple_all_trailers
+mv /tmp/c.log /home/mythtv/apple_shuffle_trailers
mv /tmp/appletrailer.2.xml /home/mythtv/appletrailer.xml
+