Mercurial > public > mercurial-scm > hg-stable
comparison mercurial/help.py @ 20743:05267e6e94dd
help: filter out deprecated options with untranslated descriptions
When using a different language than English, deprecated options were only
removed from the output of `hg help anycmd` when "DEPRECATED" in the options
description was translated.
author | Simon Heimberg <simohe@besonet.ch> |
---|---|
date | Mon, 17 Feb 2014 07:39:53 +0100 |
parents | 02c303f64917 |
children | be87397f98c9 |
comparison
equal
deleted
inserted
replaced
20742:3681de20b0a7 | 20743:05267e6e94dd |
---|---|
39 shortopt, longopt, default, desc, optlabel = option | 39 shortopt, longopt, default, desc, optlabel = option |
40 else: | 40 else: |
41 shortopt, longopt, default, desc = option | 41 shortopt, longopt, default, desc = option |
42 optlabel = _("VALUE") # default label | 42 optlabel = _("VALUE") # default label |
43 | 43 |
44 if _("DEPRECATED") in desc and not verbose: | 44 if not verbose and ("DEPRECATED" in desc or _("DEPRECATED") in desc): |
45 continue | 45 continue |
46 | 46 |
47 so = '' | 47 so = '' |
48 if shortopt: | 48 if shortopt: |
49 so = '-' + shortopt | 49 so = '-' + shortopt |