guix-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[bug#50314] [PATCH 0/2] Add hint typo for importers and system actions


From: zimoun
Subject: [bug#50314] [PATCH 0/2] Add hint typo for importers and system actions
Date: Wed, 1 Sep 2021 11:55:38 +0200

Hi,

Instead of,

        $ guix import pypy foo
        guix import: error: pypy: invalid importer

it becomes

        $ ./pre-inst-env guix import pypy foo
        guix import: error: pypy: invalid importer
        hint: Did you mean `pypi'?

And thanks to Sarah, the --options are also hinted (when typo).

Note that it is not possible to guess which importer is between 'cpan' and
'cran' for the typo 'can'.  The first from the list 'importers' is returned,
i.e., 'cpan'.

Last, instead of

        $ guix system sarch cuirass
        guix system: error: sarch: unknown action

it becomes

        $ ./pre-inst-env guix system sarch cuirass
        guix system: error: sarch: unknown action
        hint: Did you mean `search'?


All the best,
simon


zimoun (2):
  import: Add hint for importer typo.
  system: Add hint for action typo.

 guix/scripts/import.scm |  8 +++++++-
 guix/scripts/system.scm | 31 ++++++++++++++++++++-----------
 2 files changed, 27 insertions(+), 12 deletions(-)


base-commit: 1a657497acdead9afbeb24db6102f645d7e28ac9
-- 
2.29.2






reply via email to

[Prev in Thread] Current Thread [Next in Thread]