Method: Toolshed::Github#list_branches

Defined in:
lib/toolshed/github.rb

#list_branches(options = {}) ⇒ Object



36
37
38
39
40
41
42
43
# File 'lib/toolshed/github.rb', line 36

def list_branches(options={})
  options.merge!(@default_options)

  response = HTTParty.get("#{Toolshed::Client::GITHUB_BASE_API_URL}repos/#{Toolshed::Client.github_username}/toolshed/branches", options).response
  JSON.parse(response.body).each do |branch|
    puts branch.inspect
  end
end