Commit 0582a44d authored by Matthias Putz's avatar Matthias Putz

repo cmd adaption

parent 5d50e056
#!/usr/bin/env python
import sys
import portable
if sys.version_info[0] < 3:
print('git-repo is written for python3, your version is %s, please upgrade from www.python.org.' % sys.version)
exit(0)
## repo default configuration
##
from __future__ import print_function
REPO_URL = 'https://gerrit.googlesource.com/git-repo'
REPO_URL = 'ssh://gerrit/Tools/git-repo'
REPO_REV = 'stable'
# Copyright (C) 2008 Google Inc.
......@@ -21,7 +27,7 @@ REPO_REV = 'stable'
# limitations under the License.
# increment this whenever we make important changes to this script
VERSION = (1, 19)
VERSION = (1, 19, 1)
# increment this if the MAINTAINER_KEYS block is modified
KEYRING_VERSION = (1, 1)
......@@ -115,7 +121,6 @@ import os
import re
import stat
import subprocess
import sys
import urllib.request
import urllib.error
......@@ -257,7 +262,7 @@ def _CheckGitVersion():
file=sys.stderr)
raise CloneFailure()
ver_str = proc.stdout.read().strip()
ver_str = portable.stream2str(proc.stdout.read()).strip()
proc.stdout.close()
proc.wait()
......@@ -490,7 +495,7 @@ def _Verify(cwd, branch, quiet):
stdout=subprocess.PIPE,
stderr=subprocess.PIPE,
cwd = cwd)
cur = proc.stdout.read().strip()
cur = portable.stream2str(proc.stdout.read()).strip()
proc.stdout.close()
proc.stderr.read()
......@@ -663,7 +668,7 @@ def _SetDefaultsTo(gitdir):
'HEAD'],
stdout = subprocess.PIPE,
stderr = subprocess.PIPE)
REPO_REV = proc.stdout.read().strip()
REPO_REV = portable.stream2str(proc.stdout.read()).strip()
proc.stdout.close()
proc.stderr.read()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment