Skip to content

Instantly share code, notes, and snippets.

Last active December 25, 2015 18:39
What would you like to do?
Fetch the latest cartoon from and build an Atom-Feed. You can use this with newsreaders that accept commands as a feed source (e.g. newsbeuter)
# Released under the WTFPL (
toonid=`curl -s $URL | sed -n 's/^.*archiv\.php\?.*id=\([0-9]*\).*/\1/p' | sed 1q`
now=`date +%Y-%m-%dT%H:%M:%SZ`
echo -n "<?xml version=\"1.0\" encoding=\"utf-8\"?>
<feed xmlns=\"\">
<link href=\"$URL\" />
<name>Ralph Ruthe</name>
<title>Neuer Cartoon ($toonid)</title>
<summary>Neuer Cartoon!</summary>
<link rel=\"alternate\" href=\"$URL/index.php?pic=$toonid\" />
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment