Add new test mode.
This commit is contained in:
parent
abc59d2202
commit
020e79f53b
1 changed files with 15 additions and 6 deletions
|
@ -86,14 +86,23 @@ if __name__ == "__main__":
|
||||||
else:
|
else:
|
||||||
quiet = False
|
quiet = False
|
||||||
|
|
||||||
if len(sys.argv) == 2:
|
print len(sys.argv)
|
||||||
files = [{"name": sys.argv[1], "sizes": sizes_few_square}]
|
if len(sys.argv) <= 1:
|
||||||
|
active = files
|
||||||
|
elif len(sys.argv) == 2:
|
||||||
|
active = [{"name": sys.argv[1], "sizes": sizes_few_square}]
|
||||||
elif len(sys.argv) > 2:
|
elif len(sys.argv) > 2:
|
||||||
files = []
|
active = []
|
||||||
for name in sys.argv[1:]:
|
if sys.argv[1] == "-s":
|
||||||
files.append({"name": name})
|
name = sys.argv[2]
|
||||||
|
for f in files:
|
||||||
|
if f['name'] == name:
|
||||||
|
active.append(f)
|
||||||
|
else:
|
||||||
|
for name in sys.argv[1:]:
|
||||||
|
active.append({"name": name})
|
||||||
|
|
||||||
for f in files:
|
for f in active:
|
||||||
config = dict(defaults)
|
config = dict(defaults)
|
||||||
config.update(f)
|
config.update(f)
|
||||||
for size in config['sizes']:
|
for size in config['sizes']:
|
||||||
|
|
Loading…
Reference in a new issue