Mercurial > hg
changeset 10714:9c0a1887bd4b
keyword: do not bother about detecting extension path in demo
Detecting and showing the path to a keyword extension in a
non-standard place only made sense while keyword.py was not
shipped with Mercurial.
The test output has changed because we do not have a spurious
space at eol anymore.
author | Christian Ebert <blacktrash@gmx.net> |
---|---|
date | Tue, 16 Mar 2010 22:29:16 +0100 |
parents | b9c3f8e88e4f |
children | 83dce0f817f4 |
files | hgext/keyword.py tests/test-keyword.out |
diffstat | 2 files changed, 4 insertions(+), 8 deletions(-) [+] |
line wrap: on
line diff
--- a/hgext/keyword.py Tue Mar 16 22:28:58 2010 +0100 +++ b/hgext/keyword.py Tue Mar 16 22:29:16 2010 +0100 @@ -322,11 +322,7 @@ uisetup(ui) reposetup(ui, repo) - for k, v in ui.configitems('extensions'): - if k.endswith('keyword'): - extension = '%s = %s' % (k, v) - break - ui.write('[extensions]\n%s\n' % extension) + ui.write('[extensions]\nkeyword =\n') demoitems('keyword', ui.configitems('keyword')) demoitems('keywordmaps', kwmaps.iteritems()) keywords = '$' + '$\n$'.join(sorted(kwmaps.keys())) + '$\n'
--- a/tests/test-keyword.out Tue Mar 16 22:28:58 2010 +0100 +++ b/tests/test-keyword.out Tue Mar 16 22:29:16 2010 +0100 @@ -1,6 +1,6 @@ % hg kwdemo [extensions] -keyword = +keyword = [keyword] demo.txt = [keywordmaps] @@ -21,7 +21,7 @@ $Revision: xxxxxxxxxxxx $ $Source: /TMP/demo.txt,v $ [extensions] -keyword = +keyword = [keyword] demo.txt = [keywordmaps] @@ -206,7 +206,7 @@ % custom keyword expansion % try with kwdemo [extensions] -keyword = +keyword = [keyword] * = b = ignore