Skip to content

Instantly share code, notes, and snippets.

@caironoleto
Created December 18, 2009 13:20
Show Gist options
  • Save caironoleto/259488 to your computer and use it in GitHub Desktop.
Save caironoleto/259488 to your computer and use it in GitHub Desktop.
def auth
user = `/usr/local/git/bin/git config --global github.user`.strip
token = `/usr/local/git/bin/git config --global github.token`.strip
user.empty? ? {} : { 'login' => user, 'token' => token }
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment