##// END OF EJS Templates
keyword: disable expansion for annotate...
Christian Ebert -
r6667:01e95d4b default
parent child Browse files
Show More
@@ -88,7 +88,7 b' import re, shutil, tempfile, time'
88 commands.optionalrepo += ' kwdemo'
88 commands.optionalrepo += ' kwdemo'
89
89
90 # hg commands that do not act on keywords
90 # hg commands that do not act on keywords
91 nokwcommands = ('add addremove bundle copy export grep incoming init'
91 nokwcommands = ('add addremove annotate bundle copy export grep incoming init'
92 ' log outgoing push rename rollback tip'
92 ' log outgoing push rename rollback tip'
93 ' convert email glog')
93 ' convert email glog')
94
94
@@ -513,6 +513,11 b' def reposetup(ui, repo):'
513 kwt.restrict = True
513 kwt.restrict = True
514 patch_diff(repo, node1, node2, match, fp, changes, opts)
514 patch_diff(repo, node1, node2, match, fp, changes, opts)
515
515
516 def kwweb_annotate(web, req, tmpl):
517 '''Wraps webcommands.annotate turning off keyword expansion.'''
518 kwt.matcher = util.never
519 return webcommands_annotate(web, req, tmpl)
520
516 def kwweb_changeset(web, req, tmpl):
521 def kwweb_changeset(web, req, tmpl):
517 '''Wraps webcommands.changeset turning off keyword expansion.'''
522 '''Wraps webcommands.changeset turning off keyword expansion.'''
518 kwt.matcher = util.never
523 kwt.matcher = util.never
@@ -527,11 +532,13 b' def reposetup(ui, repo):'
527
532
528 patchfile_init = patch.patchfile.__init__
533 patchfile_init = patch.patchfile.__init__
529 patch_diff = patch.diff
534 patch_diff = patch.diff
535 webcommands_annotate = webcommands.annotate
530 webcommands_changeset = webcommands.changeset
536 webcommands_changeset = webcommands.changeset
531 webcommands_filediff = webcommands.filediff
537 webcommands_filediff = webcommands.filediff
532
538
533 patch.patchfile.__init__ = kwpatchfile_init
539 patch.patchfile.__init__ = kwpatchfile_init
534 patch.diff = kw_diff
540 patch.diff = kw_diff
541 webcommands.annotate = kwweb_annotate
535 webcommands.changeset = webcommands.rev = kwweb_changeset
542 webcommands.changeset = webcommands.rev = kwweb_changeset
536 webcommands.filediff = webcommands.diff = kwweb_filediff
543 webcommands.filediff = webcommands.diff = kwweb_filediff
537
544
@@ -214,6 +214,8 b' cat a b'
214 echo % hg cat
214 echo % hg cat
215 hg cat sym a b
215 hg cat sym a b
216 echo
216 echo
217 echo % annotate
218 hg annotate a
217
219
218 echo % remove
220 echo % remove
219 hg debugrebuildstate
221 hg debugrebuildstate
@@ -294,6 +294,11 b' xxx $'
294 $Xinfo: User Name <user@example.com>: firstline $
294 $Xinfo: User Name <user@example.com>: firstline $
295 ignore $Id$
295 ignore $Id$
296 a
296 a
297 % annotate
298 1: expand $Id$
299 1: do not process $Id:
300 1: xxx $
301 2: $Xinfo$
297 % remove
302 % remove
298 % status
303 % status
299 % rollback
304 % rollback
General Comments 0
You need to be logged in to leave comments. Login now