From 143d8a72495a17f8f2454fffdcc4d2599709fec5 Mon Sep 17 00:00:00 2001 From: Steve Pucci Date: Thu, 30 Jan 2014 09:45:53 -0800 Subject: [PATCH] Changes to support sso: repositories for upload Change-Id: Iddf90d52f700a1f6462abe76d4f4a367ebb6d603 --- git_config.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/git_config.py b/git_config.py index f6093a25..af09ebae 100644 --- a/git_config.py +++ b/git_config.py @@ -576,7 +576,7 @@ class Remote(object): return None u = self.review - if not u.startswith('http:') and not u.startswith('https:'): + if u.split(':')[0] not in ('http', 'https', 'sso'): u = 'http://%s' % u if u.endswith('/Gerrit'): u = u[:len(u) - len('/Gerrit')] @@ -592,6 +592,9 @@ class Remote(object): host, port = os.environ['REPO_HOST_PORT_INFO'].split() self._review_url = self._SshReviewUrl(userEmail, host, port) REVIEW_CACHE[u] = self._review_url + elif u.startswith('sso:'): + self._review_url = u # Assume it's right + REVIEW_CACHE[u] = self._review_url else: try: info_url = u + 'ssh_info'