mirror of
https://github.com/kennethreitz-archive/github2.git
synced 2026-06-05 15:40:19 +00:00
Support listing watched repositories of given username.
This commit is contained in:
@@ -91,3 +91,10 @@ class Repositories(GithubCommand):
|
||||
def branches(self, project):
|
||||
return self.make_request("show", project, "branches",
|
||||
filter="branches")
|
||||
|
||||
def watching(self, for_user=None):
|
||||
"""Lists all the repos a user is watching."""
|
||||
for_user = for_user or self.request.username
|
||||
return self.get_values("watched", for_user, filter="repositories",
|
||||
datatype=Repository)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user