diff options
author | David Pursehouse <dpursehouse@collab.net> | 2017-08-30 15:11:22 +0000 |
---|---|---|
committer | Gerrit Code Review <noreply-gerritcodereview@google.com> | 2017-08-30 15:11:22 +0000 |
commit | 9d743397bfceae24a12a566ac1f4d5f968ba2779 (patch) | |
tree | cbc177296afd38e00f82b8a0b492801381ee9a66 | |
parent | 2c57d619bca9b946eeaa4f5b88397b9e1460cf35 (diff) | |
parent | 2ec2a5d64c8f5bad7d2549720a928d4b52080d01 (diff) | |
download | git-repo-9d743397bfceae24a12a566ac1f4d5f968ba2779.tar.gz |
Merge "Fixed upload to remotes with the url ssh://hostname"
-rw-r--r-- | git_config.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/git_config.py b/git_config.py index 8f666e6d..9d5874a2 100644 --- a/git_config.py +++ b/git_config.py | |||
@@ -621,7 +621,7 @@ class Remote(object): | |||
621 | u = self.review | 621 | u = self.review |
622 | if u.startswith('persistent-'): | 622 | if u.startswith('persistent-'): |
623 | u = u[len('persistent-'):] | 623 | u = u[len('persistent-'):] |
624 | if u.split(':')[0] not in ('http', 'https', 'sso'): | 624 | if u.split(':')[0] not in ('http', 'https', 'sso', 'ssh'): |
625 | u = 'http://%s' % u | 625 | u = 'http://%s' % u |
626 | if u.endswith('/Gerrit'): | 626 | if u.endswith('/Gerrit'): |
627 | u = u[:len(u) - len('/Gerrit')] | 627 | u = u[:len(u) - len('/Gerrit')] |
@@ -637,7 +637,7 @@ class Remote(object): | |||
637 | host, port = os.environ['REPO_HOST_PORT_INFO'].split() | 637 | host, port = os.environ['REPO_HOST_PORT_INFO'].split() |
638 | self._review_url = self._SshReviewUrl(userEmail, host, port) | 638 | self._review_url = self._SshReviewUrl(userEmail, host, port) |
639 | REVIEW_CACHE[u] = self._review_url | 639 | REVIEW_CACHE[u] = self._review_url |
640 | elif u.startswith('sso:'): | 640 | elif u.startswith('sso:') or u.startswith('ssh:'): |
641 | self._review_url = u # Assume it's right | 641 | self._review_url = u # Assume it's right |
642 | REVIEW_CACHE[u] = self._review_url | 642 | REVIEW_CACHE[u] = self._review_url |
643 | elif 'REPO_IGNORE_SSH_INFO' in os.environ: | 643 | elif 'REPO_IGNORE_SSH_INFO' in os.environ: |