change parameter handling to 'action=append'

pull/186/head
Romain Primet 2018-01-09 08:22:38 +00:00
rodzic 5f95a5ddd3
commit d5d9b894b6
2 zmienionych plików z 3 dodań i 2 usunięć

Wyświetl plik

@ -300,7 +300,7 @@ class Repo2Docker(Application):
argparser.add_argument( argparser.add_argument(
'--env', '-e', '--env', '-e',
dest='environment', dest='environment',
nargs='+', action='append',
help='Environment variables to define at container run time', help='Environment variables to define at container run time',
default=[] default=[]
) )

Wyświetl plik

@ -16,7 +16,8 @@ def test_env():
subprocess.check_call([ subprocess.check_call([
'repo2docker', 'repo2docker',
'-v', '{}:/home/{}'.format(tmpdir, username), '-v', '{}:/home/{}'.format(tmpdir, username),
'-e', 'FOO={}'.format(ts), 'BAR=baz', '-e', 'FOO={}'.format(ts),
'--env', 'BAR=baz',
'--', '--',
tmpdir, tmpdir,
'/bin/bash', '/bin/bash',