Skip to content

Instantly share code, notes, and snippets.

@jgaskins
Created June 22, 2012 06:03
Show Gist options
  • Save jgaskins/2970675 to your computer and use it in GitHub Desktop.
Save jgaskins/2970675 to your computer and use it in GitHub Desktop.
See the verbs used in your commit messages
# Usage: ruby commits.rb <user> <repo>
require 'open-uri'
require 'json'
user = ARGV[0]
repo = ARGV[1]
commits = JSON.parse(open("https://github.com/#{user}/#{repo}/commits.json").read)["commits"]
messages = commits.map{ |c| c["message"] }
verbs = messages.map{ |m| m[/\w+/] }.sort.uniq
puts verbs
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment