Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

ShortyDK85

macrumors member
Original poster
Dec 11, 2011
39
0
Hello.

I've searched high and low on the internet to find an RSS feed script that can help me show the new shows that are being aired via the followshows.com website. I've found a bunch, but none of them work the way I would like them to. What I'm looking for is a script that will show the newest entries (shows that I have in my subscription) and a date ahead of each entry.

The closest I have gotten is this code:

#!/bin/sh

URL="https://followshows.com/feed/roz8a"

if [ $# -eq 1 ] ; then
headarg=$(( $1 * 2 ))
else
headarg="-20"
fi

curl --silent "$URL" | grep -E '(title>|description>)' | \
sed -n '4,$p' | \
sed -e 's/<title>//' -e 's/<\/title>//' -e 's/<description>/ /' \
-e 's/<\/description>//' | \
sed -e 's/\]\]>//g' |
head $headarg | sed G | fmt
The code does get me a few entries, but they are drowning in gibberish:

Can somebody please help me, I am a complete n00b when it comes to coding...

Best regards,
ShortyDK85
 

ShortyDK85

macrumors member
Original poster
Dec 11, 2011
39
0
Thank you for the tip, AppleSmack, but I prefer my RSS reader be present on my desktop rather than having to open a program or an app.

Browsing through the insane amount of pages in the "Your Geektool scripts" thread has helped me further though... I now only need the date to be in front of the entries, as I found this script:

curl --silent "https://followshows.com/feed/roz8a" | grep -E '(title>)' | \
sed -n '4,$p' |
sed -e 's/<title>//' -e 's/<\/title>//' |
sed -e 's/<!\[CDATA\[//g' |
sed -e 's/\]\]>//g' |
sed -e 's/<[^>]*>//g' |
sed -e '/^[ ]*$/d' |
head $headarg
which gives me this result
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.