Add checks to Python scripts for version dependencies.

Signed-off-by: Eric S. Raymond <esr@thyrsus.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
Eric S. Raymond
2012-12-28 11:40:59 -05:00
committed by Junio C Hamano
parent 18499ba694
commit a33faf2827
8 changed files with 44 additions and 3 deletions

View File

@ -31,6 +31,11 @@ from git_remote_helpers.git.exporter import GitExporter
from git_remote_helpers.git.importer import GitImporter
from git_remote_helpers.git.non_local import NonLocalGit
if sys.hexversion < 0x01050200:
# os.makedirs() is the limiter
sys.stderr.write("git-remote-testgit: requires Python 1.5.2 or later.\n")
sys.exit(1)
def get_repo(alias, url):
"""Returns a git repository object initialized for usage.
"""