diff options
| -rw-r--r-- | git_config.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/git_config.py b/git_config.py index 19c19f19..289a5b64 100644 --- a/git_config.py +++ b/git_config.py | |||
| @@ -563,6 +563,12 @@ class Remote(object): | |||
| 563 | self._review_port = info[2] | 563 | self._review_port = info[2] |
| 564 | else: | 564 | else: |
| 565 | try: | 565 | try: |
| 566 | if 'http_proxy' in os.environ: | ||
| 567 | proxy_url = os.environ['http_proxy'] | ||
| 568 | proxy_support = urllib2.ProxyHandler({"http" : proxy_url, "https" : proxy_url}) | ||
| 569 | opener = urllib2.build_opener(proxy_support) | ||
| 570 | urllib2.install_opener(opener) | ||
| 571 | |||
| 566 | info = urlopen(u).read() | 572 | info = urlopen(u).read() |
| 567 | if info == 'NOT_AVAILABLE': | 573 | if info == 'NOT_AVAILABLE': |
| 568 | raise UploadError('%s: SSH disabled' % self.review) | 574 | raise UploadError('%s: SSH disabled' % self.review) |
