Mercurial > public > mercurial-scm > hg
comparison mercurial/help.py @ 35356:7f410793c04d
py3: handle keyword arguments correctly in help.py
Differential Revision: https://phab.mercurial-scm.org/D1632
author | Pulkit Goyal <7895pulkit@gmail.com> |
---|---|
date | Sun, 10 Dec 2017 04:46:39 +0530 |
parents | b0262b25ab48 |
children | c792f7c64f0c |
comparison
equal
deleted
inserted
replaced
35355:a119e97b6caf | 35356:7f410793c04d |
---|---|
451 rst.append(" :%s: %s\n" % (commacmds, h[f])) | 451 rst.append(" :%s: %s\n" % (commacmds, h[f])) |
452 else: | 452 else: |
453 rst.append(' :%s: %s\n' % (f, h[f])) | 453 rst.append(' :%s: %s\n' % (f, h[f])) |
454 | 454 |
455 ex = opts.get | 455 ex = opts.get |
456 anyopts = (ex('keyword') or not (ex('command') or ex('extension'))) | 456 anyopts = (ex(r'keyword') or not (ex(r'command') or ex(r'extension'))) |
457 if not name and anyopts: | 457 if not name and anyopts: |
458 exts = listexts(_('enabled extensions:'), extensions.enabled()) | 458 exts = listexts(_('enabled extensions:'), extensions.enabled()) |
459 if exts: | 459 if exts: |
460 rst.append('\n') | 460 rst.append('\n') |
461 rst.extend(exts) | 461 rst.extend(exts) |