Created
August 14, 2014 19:32
-
-
Save EricZeiberg/da596bf3bdfc3f83065a to your computer and use it in GitHub Desktop.
Octokit issue
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def index | |
config = YAML.load_file("#{Rails.root}/config/github.yml")[Rails.env] | |
client = Octokit::Client.new(:access_token => "[REDACTED]") | |
user = client.user | |
user.login | |
Octokit.auto_paginate = true | |
repo = 'MasterEjay/Blog' | |
@name = 'Blog' | |
@desc = 'These are the latest changes to the blog' | |
unpaginated = client.commits(repo, :per_page => 10000) | |
@commits = unpaginated.paginate(:page => params[:page], :per_page => 15) | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment