search for: argc_minimum

Displaying 8 results from an estimated 8 matches for "argc_minimum".

2013 Dec 05
0
[PATCH 3/3] fish: improve the command error messages
...r/fish.ml | 20 ++++++++++++++++---- 1 file changed, 16 insertions(+), 4 deletions(-) diff --git a/generator/fish.ml b/generator/fish.ml index 65f1acb..da0584b 100644 --- a/generator/fish.ml +++ b/generator/fish.ml @@ -362,12 +362,24 @@ Guestfish will prompt for these separately." if argc_minimum = argc_maximum then ( pr " if (argc != %d) {\n" argc_minimum; - pr " fprintf (stderr, _(\"%%s should have %%d parameter(s)\\n\"), cmd, %d);\n" - argc_minimum; + if argc_minimum = 0 then ( + pr " fprintf (stderr, _(\&...
2013 Dec 05
6
[PATCH 0/3] Small improvements to i18n extraction/handling
Hi, here there are few patches to improve the extraction of translatable messages, and the usage of messages with plural forms. Pino Toscano (3): po: fix broken message extraction po: fix dependencies for libguestfs.pot extraction fish: improve the command error messages generator/fish.ml | 20 ++++++++++++++++---- po/Makefile.am | 24 +++++++----------------- 2 files changed, 23
2014 Dec 01
2
[PATCH v2] fish: show synopsis if command syntax is wrong
...quot;%s\",\n" (c_quote text); + pr " .synopsis = \"%s\",\n" (c_quote synopsis); pr " .run = run_%s\n" name; pr "};\n"; pr "\n"; @@ -393,30 +394,14 @@ Guestfish will prompt for these separately." if argc_minimum = argc_maximum then ( pr " if (argc != %d) {\n" argc_minimum; - if argc_minimum = 0 then ( - pr " fprintf (stderr, _(\"%%s should have no parameters\\n\"), cmd);\n"; - ) else ( - pr " fprintf (stderr, ngettext(\&quot...
2014 Dec 02
1
Re: [PATCH v2] fish: show synopsis if command syntax is wrong
...> pr "{\n"; > - pr " int ret = -1;\n"; > + pr " int ret = RUN_ERROR;\n"; > (match ret with > | RErr > | RInt _ > @@ -393,30 +399,14 @@ Guestfish will prompt for these separately." > > if argc_minimum = argc_maximum then ( > pr " if (argc != %d) {\n" argc_minimum; > - if argc_minimum = 0 then ( > - pr " fprintf (stderr, _(\"%%s should have no parameters\\n\"), cmd);\n"; > - ) else ( > - pr " fprintf...
2014 Nov 28
2
[PATCH] fish: show synopsis if command syntax is wrong
...quot;%s\",\n" (c_quote text); + pr " .synopsis = \"%s\",\n" (c_quote synopsis); pr " .run = run_%s\n" name; pr "};\n"; pr "\n"; @@ -393,30 +394,14 @@ Guestfish will prompt for these separately." if argc_minimum = argc_maximum then ( pr " if (argc != %d) {\n" argc_minimum; - if argc_minimum = 0 then ( - pr " fprintf (stderr, _(\"%%s should have no parameters\\n\"), cmd);\n"; - ) else ( - pr " fprintf (stderr, ngettext(\&quot...
2012 Mar 27
3
[PATCH 0/3] Enable FUSE support in the API via 'mount-local' call.
This patch is just for review. It enables FUSE support in the API via two new calls, 'guestfs_mount_local' and 'guestfs_umount_local'. FUSE turns out to be very easy to deadlock (necessitating that the machine be rebooted). Running the test from the third patch is usually an effective way to demonstrate this. However I have not yet managed to produce a simple reproducer that
2017 Apr 21
0
[PATCH 1/2] generator: Simplify the handling of string parameters.
...+ | StringList (_, n) -> pr " char **%s;\n" n | Bool n -> pr " int %s;\n" n | Int n -> pr " int %s;\n" n @@ -209,7 +206,7 @@ let generate_fish_run_cmds actions () = (* Check and convert parameters. *) let argc_minimum, argc_maximum = let args_no_keys = - List.filter (function Key _ -> false | _ -> true) args in + List.filter (function String (Key, _) -> false | _ -> true) args in let argc_minimum = List.length args_no_keys in let argc_maximum = argc_minimu...
2017 Apr 21
4
[PATCH 0/2] generator: Simplify the handling of string parameters.
Very large but mechanical change to the generator. Rich.