Skip to content

Instantly share code, notes, and snippets.

@IsTheJack
Created January 30, 2015 01:56
Show Gist options
  • Save IsTheJack/4066c3a5e4247b87388c to your computer and use it in GitHub Desktop.
Save IsTheJack/4066c3a5e4247b87388c to your computer and use it in GitHub Desktop.
git log as JSON...
git log --pretty=format:'{%n "commit": "%H",%n "author": "%an <%ae>",%n "date": "%ad",%n "message": "%f"%n},' $@ | perl -pe 'BEGIN{print "["}; END{print "]\n"}' | perl -pe 's/},]/}]/' > commits-log.JSON
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment