hgkw/keyword.py
changeset 836 53a9228f13de
parent 819 8f2c2cc51789
child 837 448a71a24a84
equal deleted inserted replaced
835:d3f66c4952ae 836:53a9228f13de
   572             ctx = repo['.']
   572             ctx = repo['.']
   573             modified, added = repo[None].status()[:2]
   573             modified, added = repo[None].status()[:2]
   574             ret = orig(ui, repo, commitfunc, *pats, **opts)
   574             ret = orig(ui, repo, commitfunc, *pats, **opts)
   575             recctx = repo['.']
   575             recctx = repo['.']
   576             if ctx != recctx:
   576             if ctx != recctx:
   577                 modified = [f for f in modified if f in recctx]
   577                 changed = recctx.files()
   578                 added = [f for f in added if f in recctx]
   578                 modified = [f for f in modified if f in changed]
       
   579                 added = [f for f in added if f in changed]
   579                 kwt.restrict = False
   580                 kwt.restrict = False
   580                 kwt.overwrite(recctx, modified, False, True, kwt.re_kwexp.subn)
   581                 kwt.overwrite(recctx, modified, False, True, kwt.re_kwexp.subn)
   581                 kwt.overwrite(recctx, added, False, True, kwt.re_kw.subn)
   582                 kwt.overwrite(recctx, added, False, True, kwt.re_kw.subn)
   582                 kwt.restrict = True
   583                 kwt.restrict = True
   583             return ret
   584             return ret