mirror of
https://github.com/git/git.git
synced 2025-12-12 20:36:24 +01:00
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:
committed by
Junio C Hamano
parent
18499ba694
commit
a33faf2827
@@ -9,10 +9,15 @@
|
||||
## git log --stat import-zips
|
||||
|
||||
from os import popen, path
|
||||
from sys import argv, exit
|
||||
from sys import argv, exit, hexversion, stderr
|
||||
from time import mktime
|
||||
from zipfile import ZipFile
|
||||
|
||||
if hexversion < 0x01060000:
|
||||
# The limiter is the zipfile module
|
||||
sys.stderr.write("import-zips.py: requires Python 1.6.0 or later.\n")
|
||||
sys.exit(1)
|
||||
|
||||
if len(argv) < 2:
|
||||
print 'Usage:', argv[0], '<zipfile>...'
|
||||
exit(1)
|
||||
|
||||
Reference in New Issue
Block a user