File tree 1 file changed +6
-4
lines changed
1 file changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -557,6 +557,9 @@ def main():
557
557
if not os .path .exists (name_dir ):
558
558
print ("Destination directory specified (--name-dir %s) does not exist. Will not write file." )
559
559
sys .exit (1 )
560
+ # If omitted, --counter takes on --id
561
+ if args .id and not args .counter :
562
+ argsd ['counter' ] = args .id
560
563
for arg in args .name :
561
564
if arg not in ['id' ,'timestamp' , 'counter' ]:
562
565
print ("--name may only use id, counter, and timestamp (%s found)" % arg )
@@ -569,11 +572,10 @@ def main():
569
572
name_components ['id' ] = args .id
570
573
digits = args .digits
571
574
572
- # --counter and --id can be specified separately
573
575
# If omitted, --counter takes on --id
574
- # If both are omitted, then we are not using counters in the generated names.
575
- counter_name = args .counter
576
- if not args .counter :
576
+ if args . counter :
577
+ counter_name = args .counter
578
+ elif args .id :
577
579
counter_name = args .id
578
580
579
581
if counter_name != None :
You can’t perform that action at this time.
0 commit comments