Details
Details
- Reviewers
- None
- Group Reviewers
hg-reviewers - Commits
- rHGc7ffc53fbd19: py3: use stringutil.pprint() if we are printing bool values
Diff Detail
Diff Detail
- Repository
- rHG Mercurial
- Lint
Lint Skipped - Unit
Unit Tests Skipped
hg-reviewers |
Lint Skipped |
Unit Tests Skipped |
Path | Packages | |||
---|---|---|---|---|
M | hgext/keyword.py (2 lines) |
Commit | Parents | Author | Summary | Date |
---|---|---|---|---|
Pulkit Goyal | Oct 12 2018, 9:24 PM |
Use -d/--default to disable current configuration. | Use -d/--default to disable current configuration. | ||||
See :hg:`help templates` for information on templates and filters. | See :hg:`help templates` for information on templates and filters. | ||||
''' | ''' | ||||
def demoitems(section, items): | def demoitems(section, items): | ||||
ui.write('[%s]\n' % section) | ui.write('[%s]\n' % section) | ||||
for k, v in sorted(items): | for k, v in sorted(items): | ||||
if isinstance(v, bool): | |||||
v = stringutil.pprint(v) | |||||
ui.write('%s = %s\n' % (k, v)) | ui.write('%s = %s\n' % (k, v)) | ||||
fn = 'demo.txt' | fn = 'demo.txt' | ||||
tmpdir = pycompat.mkdtemp('', 'kwdemo.') | tmpdir = pycompat.mkdtemp('', 'kwdemo.') | ||||
ui.note(_('creating temporary repository at %s\n') % tmpdir) | ui.note(_('creating temporary repository at %s\n') % tmpdir) | ||||
if repo is None: | if repo is None: | ||||
baseui = ui | baseui = ui | ||||
else: | else: |