Skip to content

Instantly share code, notes, and snippets.

@i8degrees
Created June 2, 2016 11:06
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save i8degrees/94841e6f2614cf34d21e933244fb1251 to your computer and use it in GitHub Desktop.
Save i8degrees/94841e6f2614cf34d21e933244fb1251 to your computer and use it in GitHub Desktop.
#!/bin/sh
# 2012-05/01:jeff
#
# Geeklet (GeekTools / OSX)
#
# Github Feed for justfielding
#
URL="https://github.com/justfielding.atom"
if [ $# -eq 1 ] ; then
headarg=$(( $1 * 2 ))
else
headarg="-8"
fi
curl --silent "$URL" | 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' |
head $headarg | sed G | fmt
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment