Skip to content
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

Getting private repositories for a private organization #62

Closed
cwarren-mw opened this issue Dec 13, 2013 · 1 comment
Closed

Getting private repositories for a private organization #62

cwarren-mw opened this issue Dec 13, 2013 · 1 comment

Comments

@cwarren-mw
Copy link

I've been able to list the repositories for a public organization:

GHOrganization org = gitHub.getOrganization("jenkinsci");
for (GHRepository r : org.getRepositories().values()) {
    System.out.println("Repo: " + r.getName());
}

And I've been able to list the users for a private organization (I believe this should prove I'm successfully authenticating against that organization):

GHOrganization org = gitHub.getOrganization("merchantwarehouse");
List<GHUser> users = org.getMembers();
for (GHUser user : users) {
    System.out.println("User: " + user.toString());
}

But when I try to list the repositories (all private) for the private organization, I get nothing. Have I missed a step?

My apologies if this is something that should have been obvious to me.

Thanks.

@kohsuke
Copy link
Collaborator

kohsuke commented May 10, 2014

I just tried GHOrganizatoin.listRepositories() and it was able to list all my private repositories as well.

So I assume this was fixed somewhere along the way.

@kohsuke kohsuke closed this as completed May 10, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants