diff options
author | Kris Gambirazzi <Kris@sitehost.co.nz> | 2016-04-27 11:56:33 +1200 |
---|---|---|
committer | Kris Gambirazzi <Kris@sitehost.co.nz> | 2016-04-27 11:56:33 +1200 |
commit | d4e2cd6c618d137df645c182271f67c5ae7e8ff5 (patch) | |
tree | fdcae3171aae973c51aad69ffbef9b80669a676d /gitlab/objects.py | |
parent | 61bc24fd341e53718f8b9c06c3ac1bbcd55d2530 (diff) | |
download | gitlab-d4e2cd6c618d137df645c182271f67c5ae7e8ff5.tar.gz |
list projects under group
Diffstat (limited to 'gitlab/objects.py')
-rw-r--r-- | gitlab/objects.py | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/gitlab/objects.py b/gitlab/objects.py index 2ceb37f..15799e3 100644 --- a/gitlab/objects.py +++ b/gitlab/objects.py @@ -717,6 +717,19 @@ class GroupManager(BaseManager): url = '/groups?search=' + query return self.gitlab._raw_list(url, self.obj_cls, **kwargs) + def list_projects(self, gid, **kwargs): + """List all projects in a group + + Attrs: + gid (int): ID of the group + + Raises: + GitlabConnectionError: if the server cannot be reached. + GitlabListError: If the server fails to perform the request. + """ + url = '/groups/%d/projects' % gid + return self.gitlab._raw_list(url, self.obj_cls, **kwargs) + class Hook(GitlabObject): _url = '/hooks' |