Skip to content

Instantly share code, notes, and snippets.

@quartzjer
Created July 21, 2011 16:00
Show Gist options
  • Save quartzjer/1097512 to your computer and use it in GitHub Desktop.
Save quartzjer/1097512 to your computer and use it in GitHub Desktop.
jer@six:~$ cat taily.sh
#!/bin/sh
cd Locker
git pull origin master > /dev/null
UAPP=`find . -exec grep -l "status...unstable" {} \; | xargs -L 1 basename | grep "\.app" | wc -l`
UCONN=`find . -exec grep -l "status...unstable" {} \; | xargs -L 1 basename | grep "\.connector" | wc -l`
SAPP=`find . -exec grep -l "status...stable" {} \; | xargs -L 1 basename | grep "\.app" | wc -l`
SCONN=`find . -exec grep -l "status...stable" {} \; | xargs -L 1 basename | grep "\.connector" | wc -l`
echo "{\"uapp\":\"$UAPP\",\"uconn\":\"$UCONN\",\"sapp\":\"$SAPP\",\"sconn\":\"$SCONN\"}"
jer@six:~$ crontab -l | grep taily
0 * * * * ~jer/taily.sh > /var/www/lockerproject.org/taily.json
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment