No hint for missing argument

OpenSubmitted by Julien Lepiller.
Details
2 participants
  • Julien Lepiller
  • Ludovic Courtès
Owner
unassigned
Severity
normal
J
J
Julien Lepiller wrote on 11 Jul 2019 11:49
(address . bug-guix@gnu.org)
C500F9C2-AEBB-4FE7-A826-A4A75E280031@lepiller.eu
When you type an option that requires an argument, but don't provide one, you get an error message that says there is a missing argument. There should brobably be a hint on what values are acceptable. For instance, there is no way to know from "guix package -v" or "guix package --help" what values are accepted. In other cases, there is a --list-something option.
Maybe -v is the only case where it would be useful to do something, because you could guess its existence and not use a verbosity level. Maybe fixing the help message to say --verbosity=[0-5] is enough?
L
L
Ludovic Courtès wrote on 11 Jul 2019 22:40
(name . Julien Lepiller)(address . julien@lepiller.eu)(address . 36594@debbugs.gnu.org)
87v9w8pan9.fsf@gnu.org
Julien Lepiller <julien@lepiller.eu> skribis:
Toggle quote (4 lines)> When you type an option that requires an argument, but don't provide one, you get an error message that says there is a missing argument. There should brobably be a hint on what values are acceptable. For instance, there is no way to know from "guix package -v" or "guix package --help" what values are accepted. In other cases, there is a --list-something option.>> Maybe -v is the only case where it would be useful to do something, because you could guess its existence and not use a verbosity level. Maybe fixing the help message to say --verbosity=[0-5] is enough?
Currently it says:
Toggle snippet (4 lines)$ guix build --help | grep -e -verbo -v, --verbosity=LEVEL use the given verbosity LEVEL
We could add “an integer between 0 and 2”, but this was leftnon-explicit in case we eventually extend it to -7 to +42.
Maybe there’s a limit on what we can do to help users? :-)
Ludo’.
L
L
Ludovic Courtès wrote on 11 Jul 2019 23:23
control message for bug #36594
(address . control@debbugs.gnu.org)
871rywp8oz.fsf@gnu.org
tags 36594 + easyquit
J
J
Julien Lepiller wrote on 11 Jul 2019 23:45
Re: bug#36594: No hint for missing argument
(name . Ludovic Courtès)(address . ludo@gnu.org)(address . 36594@debbugs.gnu.org)
20190711234519.10ba7cfb@sybil.lepiller.eu
Le Thu, 11 Jul 2019 22:40:58 +0200,Ludovic Courtès <ludo@gnu.org> a écrit :
Toggle quote (28 lines)> Julien Lepiller <julien@lepiller.eu> skribis:> > > When you type an option that requires an argument, but don't> > provide one, you get an error message that says there is a missing> > argument. There should brobably be a hint on what values are> > acceptable. For instance, there is no way to know from "guix> > package -v" or "guix package --help" what values are accepted. In> > other cases, there is a --list-something option.> >> > Maybe -v is the only case where it would be useful to do something,> > because you could guess its existence and not use a verbosity> > level. Maybe fixing the help message to say --verbosity=[0-5] is> > enough? > > Currently it says:> > --8<---------------cut here---------------start------------->8---> $ guix build --help | grep -e -verbo> -v, --verbosity=LEVEL use the given verbosity LEVEL> --8<---------------cut here---------------end--------------->8---> > We could add “an integer between 0 and 2”, but this was left> non-explicit in case we eventually extend it to -7 to +42.> > Maybe there’s a limit on what we can do to help users? :-)> > Ludo’.
If users have no idea what value to use though, they just won't use thefeature...
L
L
Ludovic Courtès wrote on 12 Jul 2019 22:41
(name . Julien Lepiller)(address . julien@lepiller.eu)(address . 36594@debbugs.gnu.org)
871ryvf0k4.fsf@gnu.org
Julien Lepiller <julien@lepiller.eu> skribis:
Toggle quote (3 lines)> Le Thu, 11 Jul 2019 22:40:58 +0200,> Ludovic Courtès <ludo@gnu.org> a écrit :
[...]
Toggle quote (17 lines)>> Currently it says:>> >> --8<---------------cut here---------------start------------->8--->> $ guix build --help | grep -e -verbo>> -v, --verbosity=LEVEL use the given verbosity LEVEL>> --8<---------------cut here---------------end--------------->8--->> >> We could add “an integer between 0 and 2”, but this was left>> non-explicit in case we eventually extend it to -7 to +42.>> >> Maybe there’s a limit on what we can do to help users? :-)>> >> Ludo’.>> If users have no idea what value to use though, they just won't use the> feature...
What about:
use the given verbosity LEVEL, an integer
?
If that’s fine with you, please push!
Thanks,Ludo’.
?