diff options
Diffstat (limited to 'pym')
-rw-r--r-- | pym/_emerge/depgraph.py | 4 | ||||
-rw-r--r-- | pym/_emerge/help.py | 9 | ||||
-rw-r--r-- | pym/_emerge/main.py | 6 |
3 files changed, 18 insertions, 1 deletions
diff --git a/pym/_emerge/depgraph.py b/pym/_emerge/depgraph.py index 84e7d24f1..7db5ae3f3 100644 --- a/pym/_emerge/depgraph.py +++ b/pym/_emerge/depgraph.py @@ -2757,7 +2757,9 @@ class depgraph(object): mask_docs = True else: writemsg_stdout("\nemerge: there are no ebuilds to satisfy "+green(xinfo)+".\n", noiselevel=-1) - if isinstance(myparent, AtomArg): + if isinstance(myparent, AtomArg) and \ + self._frozen_config.myopts.get( + "--misspell-suggestions", "y") != "n": cp = myparent.atom.cp.lower() cat, pkg = portage.catsplit(cp) if cat == "null": diff --git a/pym/_emerge/help.py b/pym/_emerge/help.py index a928a85fb..fb1e129e7 100644 --- a/pym/_emerge/help.py +++ b/pym/_emerge/help.py @@ -512,6 +512,15 @@ def help(myopts, havecolor=1): for line in wrap(desc, desc_width): print(desc_indent + line) print() + print(" " + green("--misspell-suggestions") + " < %s | %s >" % \ + (turquoise("y"), turquoise("n"))) + desc = "Enable or disable misspell suggestions. By default, " + \ + "emerge will show a list of packages with similar names " + \ + "when a package doesn't exist. The EMERGE_DEFAULT_OPTS " + \ + "variable may be used to disable this option by default" + for line in wrap(desc, desc_width): + print(desc_indent + line) + print() print(" "+green("--newuse")+" ("+green("-N")+" short option)") desc = "Tells emerge to include installed packages where USE " + \ "flags have changed since compilation. This option " + \ diff --git a/pym/_emerge/main.py b/pym/_emerge/main.py index 6ae267f5a..82b1444c5 100644 --- a/pym/_emerge/main.py +++ b/pym/_emerge/main.py @@ -686,6 +686,12 @@ def parse_opts(tmpcmdline, silent=False): "action" : "store" }, + "--misspell-suggestions": { + "help" : "enable package name misspell suggestions", + "type" : "choice", + "choices" : ("y", "n") + }, + "--with-bdeps": { "help":"include unnecessary build time dependencies", "type":"choice", |