Show More
@@ -308,11 +308,14 b' def parseargs(args, parser):' | |||
|
308 | 308 | sys.stderr.write('warning: --with-hg should specify an hg script\n') |
|
309 | 309 | if options.local: |
|
310 | 310 | testdir = os.path.dirname(_bytespath(canonpath(sys.argv[0]))) |
|
311 |
|
|
|
312 | if os.name != 'nt' and not os.access(hgbin, os.X_OK): | |
|
313 | parser.error('--local specified, but %r not found or not executable' | |
|
314 | % hgbin) | |
|
315 | options.with_hg = hgbin | |
|
311 | reporootdir = os.path.dirname(testdir) | |
|
312 | pathandattrs = [(b'hg', 'with_hg')] | |
|
313 | for relpath, attr in pathandattrs: | |
|
314 | binpath = os.path.join(reporootdir, relpath) | |
|
315 | if os.name != 'nt' and not os.access(binpath, os.X_OK): | |
|
316 | parser.error('--local specified, but %r not found or ' | |
|
317 | 'not executable' % binpath) | |
|
318 | setattr(options, attr, binpath) | |
|
316 | 319 | |
|
317 | 320 | if (options.chg or options.with_chg) and os.name == 'nt': |
|
318 | 321 | parser.error('chg does not work on %s' % os.name) |
General Comments 0
You need to be logged in to leave comments.
Login now