contrib/synthrepo.py
changeset 41398 2ff8994ac71d
parent 41397 0bd56c291359
child 43004 c07812bdd568
equal deleted inserted replaced
41397:0bd56c291359 41398:2ff8994ac71d
   347 
   347 
   348     # Synthesize a single initial revision adding files to the repo according
   348     # Synthesize a single initial revision adding files to the repo according
   349     # to the modeled directory structure.
   349     # to the modeled directory structure.
   350     initcount = int(opts['initfiles'])
   350     initcount = int(opts['initfiles'])
   351     if initcount and initdirs:
   351     if initcount and initdirs:
   352         pctx = repo[None].p1()
   352         pctx = repo['.']
   353         dirs = set(pctx.dirs())
   353         dirs = set(pctx.dirs())
   354         files = {}
   354         files = {}
   355 
   355 
   356         def validpath(path):
   356         def validpath(path):
   357             # Don't pick filenames which are already directory names.
   357             # Don't pick filenames which are already directory names.