Add organizations

This commit is contained in:
Vincent Jacques
2012-02-12 20:04:25 +01:00
parent 34f59de12d
commit 5f36cbc957
3 changed files with 20 additions and 1 deletions
+12
View File
@@ -23,6 +23,18 @@ NamedUser = GithubObject(
),
)
Organization = GithubObject(
"Organization",
BaseUrl( lambda obj: "/orgs/" + obj.login ),
SimpleScalarAttributes(
"login", "id", "url", "avatar_url", "name", "company", "blog",
"location", "email", "public_repos", "public_gists", "followers",
"following", "html_url", "created_at", "type",
),
ExtendedListAttribute( "public_members", NamedUser ),
ExtendedListAttribute( "members", NamedUser ),
)
Repository = GithubObject(
"Repository",
BaseUrl( lambda obj: "/repos/" + obj.owner.login + "/" + obj.name ),