New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for affiliation and visibility in RepositoryListOptions. #384

Merged
merged 1 commit into from Jun 26, 2016

Conversation

Projects
None yet
4 participants
@wlynch
Member

wlynch commented Jun 25, 2016

Also updates comments in RepositoryListOptions to match the Github API docs
(https://developer.github.com/v3/repos/#list-your-repositories).

Fixes #231.

Show outdated Hide outdated github/repos_test.go Outdated
Show outdated Hide outdated github/repos_test.go Outdated
Add support for affiliation and visibility in RepositoryListOptions.
Also updates comments in RepositoryListOptions to match the Github API docs
(https://developer.github.com/v3/repos/#list-your-repositories).

Fixes #231
@dmitshur

This comment has been minimized.

Show comment
Hide comment
@dmitshur

dmitshur Jun 25, 2016

Member

LGTM. Thank you!

Member

dmitshur commented Jun 25, 2016

LGTM. Thank you!

@willnorris willnorris merged commit 45cbf23 into google:master Jun 26, 2016

2 checks passed

cla/google All necessary CLAs are signed
continuous-integration/travis-ci/pr The Travis CI build passed
Details
@willnorris

This comment has been minimized.

Show comment
Hide comment
@willnorris

willnorris Jun 26, 2016

Member

Thanks, Billy.

Member

willnorris commented Jun 26, 2016

Thanks, Billy.

@anshumanbh

This comment has been minimized.

Show comment
Hide comment
@anshumanbh

anshumanbh Dec 5, 2017

Contributor

@wlynch @shurcooL @willnorris This PR does not seem to list the private repositories for a user when the Visibility is set to private. Can you please confirm?

Contributor

anshumanbh commented Dec 5, 2017

@wlynch @shurcooL @willnorris This PR does not seem to list the private repositories for a user when the Visibility is set to private. Can you please confirm?

@dmitshur

This comment has been minimized.

Show comment
Hide comment
@dmitshur

dmitshur Dec 5, 2017

Member

It might be because your oauth token doesn't have private repos scope. You should check whether or not the issue is in the go-github library, or on the GitHub API side by making the same request manually, without go-github, and see if the response is as expected. Then we can figure out what go-github is doing wrong, if anything.

Member

dmitshur commented Dec 5, 2017

It might be because your oauth token doesn't have private repos scope. You should check whether or not the issue is in the go-github library, or on the GitHub API side by making the same request manually, without go-github, and see if the response is as expected. Then we can figure out what go-github is doing wrong, if anything.

@anshumanbh

This comment has been minimized.

Show comment
Hide comment
@anshumanbh

anshumanbh Dec 5, 2017

Contributor

@shurcooL my oauth token had all the scopes. I figured out the issue. I think its just how the Github API works. If you provide it a valid oauth token, hitting the /users/%user%/repos will only give you public repositories. If we want to list all repositories of a user, it is a different endpoint /user/repos all together. Thanks for looking into this!

Contributor

anshumanbh commented Dec 5, 2017

@shurcooL my oauth token had all the scopes. I figured out the issue. I think its just how the Github API works. If you provide it a valid oauth token, hitting the /users/%user%/repos will only give you public repositories. If we want to list all repositories of a user, it is a different endpoint /user/repos all together. Thanks for looking into this!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment