summaryrefslogtreecommitdiffstats
path: root/repo
diff options
context:
space:
mode:
Diffstat (limited to 'repo')
-rwxr-xr-xrepo13
1 files changed, 8 insertions, 5 deletions
diff --git a/repo b/repo
index 7e7f13fa..7ffa7705 100755
--- a/repo
+++ b/repo
@@ -113,7 +113,7 @@ repodir = '.repo' # name of repo's private directory
113S_repo = 'repo' # special repo repository 113S_repo = 'repo' # special repo repository
114S_manifests = 'manifests' # special manifest repository 114S_manifests = 'manifests' # special manifest repository
115REPO_MAIN = S_repo + '/main.py' # main script 115REPO_MAIN = S_repo + '/main.py' # main script
116MIN_PYTHON_VERSION = (2, 6) # minimum supported python version 116MIN_PYTHON_VERSION = (2, 7) # minimum supported python version
117GITC_CONFIG_FILE = '/gitc/.config' 117GITC_CONFIG_FILE = '/gitc/.config'
118GITC_FS_ROOT_DIR = '/gitc/manifest-rw/' 118GITC_FS_ROOT_DIR = '/gitc/manifest-rw/'
119 119
@@ -152,9 +152,12 @@ def _print(*objects, **kwargs):
152# Python version check 152# Python version check
153ver = sys.version_info 153ver = sys.version_info
154if (ver[0], ver[1]) < MIN_PYTHON_VERSION: 154if (ver[0], ver[1]) < MIN_PYTHON_VERSION:
155 _print('error: Python version %s unsupported.\n' 155 _print('error: Python version {} unsupported.\n'
156 'Please use Python 2.6 - 2.7 instead.' 156 'Please use Python {}.{} instead.'.format(
157 % sys.version.split(' ')[0], file=sys.stderr) 157 sys.version.split(' ')[0],
158 MIN_PYTHON_VERSION[0],
159 MIN_PYTHON_VERSION[1],
160 ), file=sys.stderr)
158 sys.exit(1) 161 sys.exit(1)
159 162
160home_dot_repo = os.path.expanduser('~/.repoconfig') 163home_dot_repo = os.path.expanduser('~/.repoconfig')
@@ -909,6 +912,6 @@ def main(orig_args):
909if __name__ == '__main__': 912if __name__ == '__main__':
910 if ver[0] == 3: 913 if ver[0] == 3:
911 _print('warning: Python 3 support is currently experimental. YMMV.\n' 914 _print('warning: Python 3 support is currently experimental. YMMV.\n'
912 'Please use Python 2.6 - 2.7 instead.', 915 'Please use Python 2.7 instead.',
913 file=sys.stderr) 916 file=sys.stderr)
914 main(sys.argv[1:]) 917 main(sys.argv[1:])