hgkw/keyword.py
branchstable
changeset 593 23da65f04361
parent 590 527257649f20
child 595 1475f23ba334
equal deleted inserted replaced
591:3b4d5045a920 593:23da65f04361
   357     '''
   357     '''
   358     # 3rd argument sets expansion to True
   358     # 3rd argument sets expansion to True
   359     _kwfwrite(ui, repo, True, *pats, **opts)
   359     _kwfwrite(ui, repo, True, *pats, **opts)
   360 
   360 
   361 def files(ui, repo, *pats, **opts):
   361 def files(ui, repo, *pats, **opts):
   362     '''print files currently configured for keyword expansion
   362     '''print filenames configured for keyword expansion
   363 
   363 
   364     Crosscheck which files in working directory are potential targets
   364     Check which filenames in the working directory are matched by the
   365     for keyword expansion. That is, files matched by [keyword] config
   365     [keyword] configuration patterns.
   366     patterns but not symlinks.
   366 
       
   367     Useful to prevent inadvertent keyword expansion and to speed up
       
   368     execution by including only filenames that are actual candidates
       
   369     for expansion.
       
   370 
       
   371     Use -u/--untracked to display untracked filenames as well.
   367     '''
   372     '''
   368     kwt = kwtools['templater']
   373     kwt = kwtools['templater']
   369     status = _status(ui, repo, kwt, opts.get('untracked'), *pats, **opts)
   374     status = _status(ui, repo, kwt, opts.get('untracked'), *pats, **opts)
   370     modified, added, removed, deleted, unknown, ignored, clean = status
   375     modified, added, removed, deleted, unknown, ignored, clean = status
   371     files = sorted(modified + added + clean + unknown)
   376     files = sorted(modified + added + clean + unknown)