Mercurial > public > src > rhodecode
changeset 2094:34d009e5147a beta
added clone_uri to API method for creating users
author | Marcin Kuzminski <marcin@python-works.com> |
---|---|
date | Sun, 19 Feb 2012 20:50:00 +0200 |
parents | f2b7bebc6790 |
children | 324ac367a4da |
files | docs/api/api.rst rhodecode/controllers/api/api.py rhodecode/lib/db_manage.py |
diffstat | 3 files changed, 9 insertions(+), 7 deletions(-) [+] |
line wrap: on
line diff
--- a/docs/api/api.rst Sun Feb 19 20:16:51 2012 +0200 +++ b/docs/api/api.rst Sun Feb 19 20:50:00 2012 +0200 @@ -491,7 +491,8 @@ "owner_name" : "<ownername>", "description" : "<description> = ''", "repo_type" : "<type> = 'hg'", - "private" : "<bool> = False" + "private" : "<bool> = False", + "clone_uri" : "<clone_uri> = None", } OUTPUT::
--- a/rhodecode/controllers/api/api.py Sun Feb 19 20:16:51 2012 +0200 +++ b/rhodecode/controllers/api/api.py Sun Feb 19 20:50:00 2012 +0200 @@ -439,16 +439,17 @@ @HasPermissionAnyDecorator('hg.admin', 'hg.create.repository') def create_repo(self, apiuser, repo_name, owner_name, description='', - repo_type='hg', private=False): + repo_type='hg', private=False, clone_uri=None): """ - Create a repository + Create repository, if clone_url is given it makes a remote clone :param apiuser: :param repo_name: + :param owner_name: :param description: - :param type: + :param repo_type: :param private: - :param owner_name: + :param clone_uri: """ try: @@ -477,7 +478,7 @@ private=private, repo_type=repo_type, repo_group=parent_id, - clone_uri=None + clone_uri=clone_uri ), owner )