mirror of
https://github.com/cuberite/TCLAP.git
synced 2025-09-12 13:46:02 -04:00
changed error output and added usage stuff
This commit is contained in:
parent
847ea3a4fc
commit
dc0aa2daf3
@ -38,7 +38,14 @@ TESTS = test1.sh \
|
||||
test36.sh \
|
||||
test37.sh \
|
||||
test38.sh \
|
||||
test39.sh
|
||||
test39.sh \
|
||||
test40.sh \
|
||||
test41.sh \
|
||||
test42.sh \
|
||||
test43.sh \
|
||||
test44.sh \
|
||||
test45.sh \
|
||||
test46.sh
|
||||
|
||||
EXTRA_DIST = $(TESTS) \
|
||||
test1.out \
|
||||
@ -79,5 +86,12 @@ EXTRA_DIST = $(TESTS) \
|
||||
test36.out \
|
||||
test37.out \
|
||||
test38.out \
|
||||
test39.out
|
||||
test39.out \
|
||||
test40.out \
|
||||
test41.out \
|
||||
test42.out \
|
||||
test43.out \
|
||||
test44.out \
|
||||
test45.out \
|
||||
test46.out
|
||||
|
||||
|
@ -1,47 +1,10 @@
|
||||
PARSE ERROR:
|
||||
One or more required arguments missing!
|
||||
|
||||
Brief USAGE:
|
||||
../examples/test2 [-f <float>] -i <int> -s <string> [-A] [-C] [-B] [--]
|
||||
[-v] [-h] <string> <string> ...
|
||||
|
||||
USAGE:
|
||||
|
||||
../examples/test2 [-f <float>] -i <int> -s <string> [-A] [-C] [-B] [--] [-v] [-h] <string> <string> ...
|
||||
|
||||
Where:
|
||||
|
||||
-f <float>, --floatTest <float>
|
||||
(value required) float test
|
||||
|
||||
-i <int>, --intTest <int>
|
||||
(required) (value required) integer test
|
||||
|
||||
-s <string>, --stringTest <string>
|
||||
(required) (value required) string test
|
||||
|
||||
-A, --existTestA
|
||||
tests for the existence of A
|
||||
|
||||
-C, --existTestC
|
||||
tests for the existence of C
|
||||
|
||||
-B, --existTestB
|
||||
tests for the existence of B
|
||||
|
||||
--, --ignore_rest
|
||||
Ignores the rest of the labeled arguments following this flag.
|
||||
|
||||
-v, --version
|
||||
Displays version information and exits.
|
||||
|
||||
-h, --help
|
||||
Displays usage information and exits.
|
||||
|
||||
<string>
|
||||
(required) (value required) unlabeld test
|
||||
|
||||
<string> (accepted multiple times)
|
||||
(value required) file names
|
||||
|
||||
|
||||
|
||||
this is a message
|
||||
For complete USAGE and HELP type:
|
||||
../examples/test2 --help
|
||||
|
||||
|
@ -1,47 +1,10 @@
|
||||
PARSE ERROR: Argument: -i (--intTest)
|
||||
Argument already set!
|
||||
|
||||
Brief USAGE:
|
||||
../examples/test2 [-f <float>] -i <int> -s <string> [-A] [-C] [-B] [--]
|
||||
[-v] [-h] <string> <string> ...
|
||||
|
||||
USAGE:
|
||||
|
||||
../examples/test2 [-f <float>] -i <int> -s <string> [-A] [-C] [-B] [--] [-v] [-h] <string> <string> ...
|
||||
|
||||
Where:
|
||||
|
||||
-f <float>, --floatTest <float>
|
||||
(value required) float test
|
||||
|
||||
-i <int>, --intTest <int>
|
||||
(required) (value required) integer test
|
||||
|
||||
-s <string>, --stringTest <string>
|
||||
(required) (value required) string test
|
||||
|
||||
-A, --existTestA
|
||||
tests for the existence of A
|
||||
|
||||
-C, --existTestC
|
||||
tests for the existence of C
|
||||
|
||||
-B, --existTestB
|
||||
tests for the existence of B
|
||||
|
||||
--, --ignore_rest
|
||||
Ignores the rest of the labeled arguments following this flag.
|
||||
|
||||
-v, --version
|
||||
Displays version information and exits.
|
||||
|
||||
-h, --help
|
||||
Displays usage information and exits.
|
||||
|
||||
<string>
|
||||
(required) (value required) unlabeld test
|
||||
|
||||
<string> (accepted multiple times)
|
||||
(value required) file names
|
||||
|
||||
|
||||
|
||||
this is a message
|
||||
For complete USAGE and HELP type:
|
||||
../examples/test2 --help
|
||||
|
||||
|
@ -1,47 +1,10 @@
|
||||
PARSE ERROR: Argument: -f (--floatTest)
|
||||
Couldn't read argument value from string 'nine'
|
||||
|
||||
Brief USAGE:
|
||||
../examples/test2 [-f <float>] -i <int> -s <string> [-A] [-C] [-B] [--]
|
||||
[-v] [-h] <string> <string> ...
|
||||
|
||||
USAGE:
|
||||
|
||||
../examples/test2 [-f <float>] -i <int> -s <string> [-A] [-C] [-B] [--] [-v] [-h] <string> <string> ...
|
||||
|
||||
Where:
|
||||
|
||||
-f <float>, --floatTest <float>
|
||||
(value required) float test
|
||||
|
||||
-i <int>, --intTest <int>
|
||||
(required) (value required) integer test
|
||||
|
||||
-s <string>, --stringTest <string>
|
||||
(required) (value required) string test
|
||||
|
||||
-A, --existTestA
|
||||
tests for the existence of A
|
||||
|
||||
-C, --existTestC
|
||||
tests for the existence of C
|
||||
|
||||
-B, --existTestB
|
||||
tests for the existence of B
|
||||
|
||||
--, --ignore_rest
|
||||
Ignores the rest of the labeled arguments following this flag.
|
||||
|
||||
-v, --version
|
||||
Displays version information and exits.
|
||||
|
||||
-h, --help
|
||||
Displays usage information and exits.
|
||||
|
||||
<string>
|
||||
(required) (value required) unlabeld test
|
||||
|
||||
<string> (accepted multiple times)
|
||||
(value required) file names
|
||||
|
||||
|
||||
|
||||
this is a message
|
||||
For complete USAGE and HELP type:
|
||||
../examples/test2 --help
|
||||
|
||||
|
@ -1,44 +1,10 @@
|
||||
PARSE ERROR: Argument: -s (--stringTest)
|
||||
Couldn't find delimiter for this argument!
|
||||
|
||||
Brief USAGE:
|
||||
../examples/test3 [-f=<float>] ... [-i=<int>] ... -s=<string> [-B]
|
||||
[--] [-v] [-h] <string> <string> <fileNameString> ...
|
||||
|
||||
USAGE:
|
||||
|
||||
../examples/test3 [-f=<float>] ... [-i=<int>] ... -s=<string> [-B] [--] [-v] [-h] <string> <string> <fileNameString> ...
|
||||
|
||||
Where:
|
||||
|
||||
-f <float>, --floatTest <float> (accepted multiple times)
|
||||
(value required) multi float test
|
||||
|
||||
-i <int>, --intTest <int> (accepted multiple times)
|
||||
(value required) multi int test
|
||||
|
||||
-s <string>, --stringTest <string>
|
||||
(required) (value required) string test
|
||||
|
||||
-B, --existTestB
|
||||
exist Test B
|
||||
|
||||
--, --ignore_rest
|
||||
Ignores the rest of the labeled arguments following this flag.
|
||||
|
||||
-v, --version
|
||||
Displays version information and exits.
|
||||
|
||||
-h, --help
|
||||
Displays usage information and exits.
|
||||
|
||||
<string>
|
||||
(required) (value required) unlabeled test one
|
||||
|
||||
<string>
|
||||
(required) (value required) unlabeled test two
|
||||
|
||||
<fileNameString> (accepted multiple times)
|
||||
(value required) file names
|
||||
|
||||
|
||||
|
||||
this is a message
|
||||
For complete USAGE and HELP type:
|
||||
../examples/test3 --help
|
||||
|
||||
|
@ -1,44 +1,10 @@
|
||||
PARSE ERROR: Argument: -s (--stringTest)
|
||||
Couldn't find delimiter for this argument!
|
||||
|
||||
Brief USAGE:
|
||||
../examples/test3 [-f=<float>] ... [-i=<int>] ... -s=<string> [-B]
|
||||
[--] [-v] [-h] <string> <string> <fileNameString> ...
|
||||
|
||||
USAGE:
|
||||
|
||||
../examples/test3 [-f=<float>] ... [-i=<int>] ... -s=<string> [-B] [--] [-v] [-h] <string> <string> <fileNameString> ...
|
||||
|
||||
Where:
|
||||
|
||||
-f <float>, --floatTest <float> (accepted multiple times)
|
||||
(value required) multi float test
|
||||
|
||||
-i <int>, --intTest <int> (accepted multiple times)
|
||||
(value required) multi int test
|
||||
|
||||
-s <string>, --stringTest <string>
|
||||
(required) (value required) string test
|
||||
|
||||
-B, --existTestB
|
||||
exist Test B
|
||||
|
||||
--, --ignore_rest
|
||||
Ignores the rest of the labeled arguments following this flag.
|
||||
|
||||
-v, --version
|
||||
Displays version information and exits.
|
||||
|
||||
-h, --help
|
||||
Displays usage information and exits.
|
||||
|
||||
<string>
|
||||
(required) (value required) unlabeled test one
|
||||
|
||||
<string>
|
||||
(required) (value required) unlabeled test two
|
||||
|
||||
<fileNameString> (accepted multiple times)
|
||||
(value required) file names
|
||||
|
||||
|
||||
|
||||
this is a message
|
||||
For complete USAGE and HELP type:
|
||||
../examples/test3 --help
|
||||
|
||||
|
@ -1,44 +1,10 @@
|
||||
PARSE ERROR:
|
||||
One or more required arguments missing!
|
||||
|
||||
Brief USAGE:
|
||||
../examples/test3 [-f=<float>] ... [-i=<int>] ... -s=<string> [-B]
|
||||
[--] [-v] [-h] <string> <string> <fileNameString> ...
|
||||
|
||||
USAGE:
|
||||
|
||||
../examples/test3 [-f=<float>] ... [-i=<int>] ... -s=<string> [-B] [--] [-v] [-h] <string> <string> <fileNameString> ...
|
||||
|
||||
Where:
|
||||
|
||||
-f <float>, --floatTest <float> (accepted multiple times)
|
||||
(value required) multi float test
|
||||
|
||||
-i <int>, --intTest <int> (accepted multiple times)
|
||||
(value required) multi int test
|
||||
|
||||
-s <string>, --stringTest <string>
|
||||
(required) (value required) string test
|
||||
|
||||
-B, --existTestB
|
||||
exist Test B
|
||||
|
||||
--, --ignore_rest
|
||||
Ignores the rest of the labeled arguments following this flag.
|
||||
|
||||
-v, --version
|
||||
Displays version information and exits.
|
||||
|
||||
-h, --help
|
||||
Displays usage information and exits.
|
||||
|
||||
<string>
|
||||
(required) (value required) unlabeled test one
|
||||
|
||||
<string>
|
||||
(required) (value required) unlabeled test two
|
||||
|
||||
<fileNameString> (accepted multiple times)
|
||||
(value required) file names
|
||||
|
||||
|
||||
|
||||
this is a message
|
||||
For complete USAGE and HELP type:
|
||||
../examples/test3 --help
|
||||
|
||||
|
@ -1,32 +1,9 @@
|
||||
PARSE ERROR: Argument: -*s
|
||||
Couldn't find match for argument
|
||||
|
||||
|
||||
USAGE:
|
||||
|
||||
Brief USAGE:
|
||||
../examples/test4 [-A] [-B] -s <string> [--] [-v] [-h]
|
||||
|
||||
Where:
|
||||
|
||||
-A, --sA
|
||||
exist Test B
|
||||
|
||||
-B, --sB
|
||||
exist Test B
|
||||
|
||||
-s <string>, --Bs <string>
|
||||
(required) (value required) string test
|
||||
|
||||
--, --ignore_rest
|
||||
Ignores the rest of the labeled arguments following this flag.
|
||||
|
||||
-v, --version
|
||||
Displays version information and exits.
|
||||
|
||||
-h, --help
|
||||
Displays usage information and exits.
|
||||
|
||||
|
||||
|
||||
this is a message
|
||||
For complete USAGE and HELP type:
|
||||
../examples/test4 --help
|
||||
|
||||
|
@ -1,46 +1,10 @@
|
||||
PARSE ERROR: Argument: -b (--bbb)
|
||||
Argument already set!
|
||||
|
||||
Brief USAGE:
|
||||
../examples/test5 {-a <string>|-b <string>} {--eee <string>|--fff
|
||||
<string>|-g <string>} [--ddd] -c <string> [--] [-v] [-h]
|
||||
|
||||
USAGE:
|
||||
|
||||
../examples/test5 {-a <string>|-b <string>} {--eee <string>|--fff <string>|-g <string>} [--ddd] -c <string> [--] [-v] [-h]
|
||||
|
||||
Where:
|
||||
|
||||
-a <string>, --aaa <string>
|
||||
(OR required) (value required) or test a
|
||||
-- OR --
|
||||
-b <string>, --bbb <string>
|
||||
(OR required) (value required) or test b
|
||||
|
||||
|
||||
--eee <string>
|
||||
(OR required) (value required) e test
|
||||
-- OR --
|
||||
--fff <string>
|
||||
(OR required) (value required) f test
|
||||
-- OR --
|
||||
-g <string>, --ggg <string>
|
||||
(OR required) (value required) g test
|
||||
|
||||
|
||||
--ddd
|
||||
d test
|
||||
|
||||
-c <string>, --ccc <string>
|
||||
(required) (value required) c test
|
||||
|
||||
--, --ignore_rest
|
||||
Ignores the rest of the labeled arguments following this flag.
|
||||
|
||||
-v, --version
|
||||
Displays version information and exits.
|
||||
|
||||
-h, --help
|
||||
Displays usage information and exits.
|
||||
|
||||
|
||||
|
||||
this is a message
|
||||
For complete USAGE and HELP type:
|
||||
../examples/test5 --help
|
||||
|
||||
|
@ -1,46 +1,10 @@
|
||||
PARSE ERROR: Argument: -d
|
||||
Couldn't find match for argument
|
||||
|
||||
Brief USAGE:
|
||||
../examples/test5 {-a <string>|-b <string>} {--eee <string>|--fff
|
||||
<string>|-g <string>} [--ddd] -c <string> [--] [-v] [-h]
|
||||
|
||||
USAGE:
|
||||
|
||||
../examples/test5 {-a <string>|-b <string>} {--eee <string>|--fff <string>|-g <string>} [--ddd] -c <string> [--] [-v] [-h]
|
||||
|
||||
Where:
|
||||
|
||||
-a <string>, --aaa <string>
|
||||
(OR required) (value required) or test a
|
||||
-- OR --
|
||||
-b <string>, --bbb <string>
|
||||
(OR required) (value required) or test b
|
||||
|
||||
|
||||
--eee <string>
|
||||
(OR required) (value required) e test
|
||||
-- OR --
|
||||
--fff <string>
|
||||
(OR required) (value required) f test
|
||||
-- OR --
|
||||
-g <string>, --ggg <string>
|
||||
(OR required) (value required) g test
|
||||
|
||||
|
||||
--ddd
|
||||
d test
|
||||
|
||||
-c <string>, --ccc <string>
|
||||
(required) (value required) c test
|
||||
|
||||
--, --ignore_rest
|
||||
Ignores the rest of the labeled arguments following this flag.
|
||||
|
||||
-v, --version
|
||||
Displays version information and exits.
|
||||
|
||||
-h, --help
|
||||
Displays usage information and exits.
|
||||
|
||||
|
||||
|
||||
this is a message
|
||||
For complete USAGE and HELP type:
|
||||
../examples/test5 --help
|
||||
|
||||
|
@ -1,46 +1,10 @@
|
||||
PARSE ERROR: Argument: -b (--bbb)
|
||||
Argument already set!
|
||||
|
||||
Brief USAGE:
|
||||
../examples/test5 {-a <string>|-b <string>} {--eee <string>|--fff
|
||||
<string>|-g <string>} [--ddd] -c <string> [--] [-v] [-h]
|
||||
|
||||
USAGE:
|
||||
|
||||
../examples/test5 {-a <string>|-b <string>} {--eee <string>|--fff <string>|-g <string>} [--ddd] -c <string> [--] [-v] [-h]
|
||||
|
||||
Where:
|
||||
|
||||
-a <string>, --aaa <string>
|
||||
(OR required) (value required) or test a
|
||||
-- OR --
|
||||
-b <string>, --bbb <string>
|
||||
(OR required) (value required) or test b
|
||||
|
||||
|
||||
--eee <string>
|
||||
(OR required) (value required) e test
|
||||
-- OR --
|
||||
--fff <string>
|
||||
(OR required) (value required) f test
|
||||
-- OR --
|
||||
-g <string>, --ggg <string>
|
||||
(OR required) (value required) g test
|
||||
|
||||
|
||||
--ddd
|
||||
d test
|
||||
|
||||
-c <string>, --ccc <string>
|
||||
(required) (value required) c test
|
||||
|
||||
--, --ignore_rest
|
||||
Ignores the rest of the labeled arguments following this flag.
|
||||
|
||||
-v, --version
|
||||
Displays version information and exits.
|
||||
|
||||
-h, --help
|
||||
Displays usage information and exits.
|
||||
|
||||
|
||||
|
||||
this is a message
|
||||
For complete USAGE and HELP type:
|
||||
../examples/test5 --help
|
||||
|
||||
|
@ -1,47 +1,10 @@
|
||||
PARSE ERROR: Argument: -f (--floatTest)
|
||||
More than one valid value parsed from string '4..2'
|
||||
|
||||
Brief USAGE:
|
||||
../examples/test2 [-f <float>] -i <int> -s <string> [-A] [-C] [-B] [--]
|
||||
[-v] [-h] <string> <string> ...
|
||||
|
||||
USAGE:
|
||||
|
||||
../examples/test2 [-f <float>] -i <int> -s <string> [-A] [-C] [-B] [--] [-v] [-h] <string> <string> ...
|
||||
|
||||
Where:
|
||||
|
||||
-f <float>, --floatTest <float>
|
||||
(value required) float test
|
||||
|
||||
-i <int>, --intTest <int>
|
||||
(required) (value required) integer test
|
||||
|
||||
-s <string>, --stringTest <string>
|
||||
(required) (value required) string test
|
||||
|
||||
-A, --existTestA
|
||||
tests for the existence of A
|
||||
|
||||
-C, --existTestC
|
||||
tests for the existence of C
|
||||
|
||||
-B, --existTestB
|
||||
tests for the existence of B
|
||||
|
||||
--, --ignore_rest
|
||||
Ignores the rest of the labeled arguments following this flag.
|
||||
|
||||
-v, --version
|
||||
Displays version information and exits.
|
||||
|
||||
-h, --help
|
||||
Displays usage information and exits.
|
||||
|
||||
<string>
|
||||
(required) (value required) unlabeld test
|
||||
|
||||
<string> (accepted multiple times)
|
||||
(value required) file names
|
||||
|
||||
|
||||
|
||||
this is a message
|
||||
For complete USAGE and HELP type:
|
||||
../examples/test2 --help
|
||||
|
||||
|
@ -1,47 +1,10 @@
|
||||
PARSE ERROR: Argument: -f (--floatTest)
|
||||
More than one valid value parsed from string '4.0.2'
|
||||
|
||||
Brief USAGE:
|
||||
../examples/test2 [-f <float>] -i <int> -s <string> [-A] [-C] [-B] [--]
|
||||
[-v] [-h] <string> <string> ...
|
||||
|
||||
USAGE:
|
||||
|
||||
../examples/test2 [-f <float>] -i <int> -s <string> [-A] [-C] [-B] [--] [-v] [-h] <string> <string> ...
|
||||
|
||||
Where:
|
||||
|
||||
-f <float>, --floatTest <float>
|
||||
(value required) float test
|
||||
|
||||
-i <int>, --intTest <int>
|
||||
(required) (value required) integer test
|
||||
|
||||
-s <string>, --stringTest <string>
|
||||
(required) (value required) string test
|
||||
|
||||
-A, --existTestA
|
||||
tests for the existence of A
|
||||
|
||||
-C, --existTestC
|
||||
tests for the existence of C
|
||||
|
||||
-B, --existTestB
|
||||
tests for the existence of B
|
||||
|
||||
--, --ignore_rest
|
||||
Ignores the rest of the labeled arguments following this flag.
|
||||
|
||||
-v, --version
|
||||
Displays version information and exits.
|
||||
|
||||
-h, --help
|
||||
Displays usage information and exits.
|
||||
|
||||
<string>
|
||||
(required) (value required) unlabeld test
|
||||
|
||||
<string> (accepted multiple times)
|
||||
(value required) file names
|
||||
|
||||
|
||||
|
||||
this is a message
|
||||
For complete USAGE and HELP type:
|
||||
../examples/test2 --help
|
||||
|
||||
|
@ -1,47 +1,10 @@
|
||||
PARSE ERROR: Argument: -i (--intTest)
|
||||
Couldn't read argument value from string '2a'
|
||||
|
||||
Brief USAGE:
|
||||
../examples/test2 [-f <float>] -i <int> -s <string> [-A] [-C] [-B] [--]
|
||||
[-v] [-h] <string> <string> ...
|
||||
|
||||
USAGE:
|
||||
|
||||
../examples/test2 [-f <float>] -i <int> -s <string> [-A] [-C] [-B] [--] [-v] [-h] <string> <string> ...
|
||||
|
||||
Where:
|
||||
|
||||
-f <float>, --floatTest <float>
|
||||
(value required) float test
|
||||
|
||||
-i <int>, --intTest <int>
|
||||
(required) (value required) integer test
|
||||
|
||||
-s <string>, --stringTest <string>
|
||||
(required) (value required) string test
|
||||
|
||||
-A, --existTestA
|
||||
tests for the existence of A
|
||||
|
||||
-C, --existTestC
|
||||
tests for the existence of C
|
||||
|
||||
-B, --existTestB
|
||||
tests for the existence of B
|
||||
|
||||
--, --ignore_rest
|
||||
Ignores the rest of the labeled arguments following this flag.
|
||||
|
||||
-v, --version
|
||||
Displays version information and exits.
|
||||
|
||||
-h, --help
|
||||
Displays usage information and exits.
|
||||
|
||||
<string>
|
||||
(required) (value required) unlabeld test
|
||||
|
||||
<string> (accepted multiple times)
|
||||
(value required) file names
|
||||
|
||||
|
||||
|
||||
this is a message
|
||||
For complete USAGE and HELP type:
|
||||
../examples/test2 --help
|
||||
|
||||
|
@ -1,47 +1,10 @@
|
||||
PARSE ERROR: Argument: -i (--intTest)
|
||||
Couldn't read argument value from string '0x2'
|
||||
|
||||
Brief USAGE:
|
||||
../examples/test2 [-f <float>] -i <int> -s <string> [-A] [-C] [-B] [--]
|
||||
[-v] [-h] <string> <string> ...
|
||||
|
||||
USAGE:
|
||||
|
||||
../examples/test2 [-f <float>] -i <int> -s <string> [-A] [-C] [-B] [--] [-v] [-h] <string> <string> ...
|
||||
|
||||
Where:
|
||||
|
||||
-f <float>, --floatTest <float>
|
||||
(value required) float test
|
||||
|
||||
-i <int>, --intTest <int>
|
||||
(required) (value required) integer test
|
||||
|
||||
-s <string>, --stringTest <string>
|
||||
(required) (value required) string test
|
||||
|
||||
-A, --existTestA
|
||||
tests for the existence of A
|
||||
|
||||
-C, --existTestC
|
||||
tests for the existence of C
|
||||
|
||||
-B, --existTestB
|
||||
tests for the existence of B
|
||||
|
||||
--, --ignore_rest
|
||||
Ignores the rest of the labeled arguments following this flag.
|
||||
|
||||
-v, --version
|
||||
Displays version information and exits.
|
||||
|
||||
-h, --help
|
||||
Displays usage information and exits.
|
||||
|
||||
<string>
|
||||
(required) (value required) unlabeld test
|
||||
|
||||
<string> (accepted multiple times)
|
||||
(value required) file names
|
||||
|
||||
|
||||
|
||||
this is a message
|
||||
For complete USAGE and HELP type:
|
||||
../examples/test2 --help
|
||||
|
||||
|
@ -1,47 +1,10 @@
|
||||
PARSE ERROR: Argument: -i (--intTest)
|
||||
Couldn't read argument value from string '2.1'
|
||||
|
||||
Brief USAGE:
|
||||
../examples/test2 [-f <float>] -i <int> -s <string> [-A] [-C] [-B] [--]
|
||||
[-v] [-h] <string> <string> ...
|
||||
|
||||
USAGE:
|
||||
|
||||
../examples/test2 [-f <float>] -i <int> -s <string> [-A] [-C] [-B] [--] [-v] [-h] <string> <string> ...
|
||||
|
||||
Where:
|
||||
|
||||
-f <float>, --floatTest <float>
|
||||
(value required) float test
|
||||
|
||||
-i <int>, --intTest <int>
|
||||
(required) (value required) integer test
|
||||
|
||||
-s <string>, --stringTest <string>
|
||||
(required) (value required) string test
|
||||
|
||||
-A, --existTestA
|
||||
tests for the existence of A
|
||||
|
||||
-C, --existTestC
|
||||
tests for the existence of C
|
||||
|
||||
-B, --existTestB
|
||||
tests for the existence of B
|
||||
|
||||
--, --ignore_rest
|
||||
Ignores the rest of the labeled arguments following this flag.
|
||||
|
||||
-v, --version
|
||||
Displays version information and exits.
|
||||
|
||||
-h, --help
|
||||
Displays usage information and exits.
|
||||
|
||||
<string>
|
||||
(required) (value required) unlabeld test
|
||||
|
||||
<string> (accepted multiple times)
|
||||
(value required) file names
|
||||
|
||||
|
||||
|
||||
this is a message
|
||||
For complete USAGE and HELP type:
|
||||
../examples/test2 --help
|
||||
|
||||
|
@ -1,44 +1,10 @@
|
||||
PARSE ERROR: Argument: -i (--intTest)
|
||||
Couldn't read argument value from string '9a'
|
||||
|
||||
Brief USAGE:
|
||||
../examples/test3 [-f=<float>] ... [-i=<int>] ... -s=<string> [-B]
|
||||
[--] [-v] [-h] <string> <string> <fileNameString> ...
|
||||
|
||||
USAGE:
|
||||
|
||||
../examples/test3 [-f=<float>] ... [-i=<int>] ... -s=<string> [-B] [--] [-v] [-h] <string> <string> <fileNameString> ...
|
||||
|
||||
Where:
|
||||
|
||||
-f <float>, --floatTest <float> (accepted multiple times)
|
||||
(value required) multi float test
|
||||
|
||||
-i <int>, --intTest <int> (accepted multiple times)
|
||||
(value required) multi int test
|
||||
|
||||
-s <string>, --stringTest <string>
|
||||
(required) (value required) string test
|
||||
|
||||
-B, --existTestB
|
||||
exist Test B
|
||||
|
||||
--, --ignore_rest
|
||||
Ignores the rest of the labeled arguments following this flag.
|
||||
|
||||
-v, --version
|
||||
Displays version information and exits.
|
||||
|
||||
-h, --help
|
||||
Displays usage information and exits.
|
||||
|
||||
<string>
|
||||
(required) (value required) unlabeled test one
|
||||
|
||||
<string>
|
||||
(required) (value required) unlabeled test two
|
||||
|
||||
<fileNameString> (accepted multiple times)
|
||||
(value required) file names
|
||||
|
||||
|
||||
|
||||
this is a message
|
||||
For complete USAGE and HELP type:
|
||||
../examples/test3 --help
|
||||
|
||||
|
@ -1,44 +1,10 @@
|
||||
PARSE ERROR: Argument: -f (--floatTest)
|
||||
More than one valid value parsed from string '1.0.0'
|
||||
|
||||
Brief USAGE:
|
||||
../examples/test3 [-f=<float>] ... [-i=<int>] ... -s=<string> [-B]
|
||||
[--] [-v] [-h] <string> <string> <fileNameString> ...
|
||||
|
||||
USAGE:
|
||||
|
||||
../examples/test3 [-f=<float>] ... [-i=<int>] ... -s=<string> [-B] [--] [-v] [-h] <string> <string> <fileNameString> ...
|
||||
|
||||
Where:
|
||||
|
||||
-f <float>, --floatTest <float> (accepted multiple times)
|
||||
(value required) multi float test
|
||||
|
||||
-i <int>, --intTest <int> (accepted multiple times)
|
||||
(value required) multi int test
|
||||
|
||||
-s <string>, --stringTest <string>
|
||||
(required) (value required) string test
|
||||
|
||||
-B, --existTestB
|
||||
exist Test B
|
||||
|
||||
--, --ignore_rest
|
||||
Ignores the rest of the labeled arguments following this flag.
|
||||
|
||||
-v, --version
|
||||
Displays version information and exits.
|
||||
|
||||
-h, --help
|
||||
Displays usage information and exits.
|
||||
|
||||
<string>
|
||||
(required) (value required) unlabeled test one
|
||||
|
||||
<string>
|
||||
(required) (value required) unlabeled test two
|
||||
|
||||
<fileNameString> (accepted multiple times)
|
||||
(value required) file names
|
||||
|
||||
|
||||
|
||||
this is a message
|
||||
For complete USAGE and HELP type:
|
||||
../examples/test3 --help
|
||||
|
||||
|
@ -1,29 +1,10 @@
|
||||
PARSE ERROR: Argument: -n (--name)
|
||||
Couldn't find 'mike' in allowed list.
|
||||
|
||||
Brief USAGE:
|
||||
../examples/test6 -n <homer|marge|bart|lisa|maggie> [--] [-v] [-h] <1|2
|
||||
|3>
|
||||
|
||||
USAGE:
|
||||
|
||||
../examples/test6 -n <homer,marge,bart,lisa,maggie> [--] [-v] [-h] <1,2,3>
|
||||
|
||||
Where:
|
||||
|
||||
-n <homer,marge,bart,lisa,maggie>, --name <homer,marge,bart,lisa,maggie>
|
||||
(required) (value required) Name to print
|
||||
|
||||
--, --ignore_rest
|
||||
Ignores the rest of the labeled arguments following this flag.
|
||||
|
||||
-v, --version
|
||||
Displays version information and exits.
|
||||
|
||||
-h, --help
|
||||
Displays usage information and exits.
|
||||
|
||||
<1,2,3>
|
||||
(required) (value required) Number of times to print
|
||||
|
||||
|
||||
|
||||
Command description message
|
||||
For complete USAGE and HELP type:
|
||||
../examples/test6 --help
|
||||
|
||||
|
@ -1,29 +1,10 @@
|
||||
PARSE ERROR: Argument: (--times)
|
||||
Couldn't find '6' in allowed list.
|
||||
|
||||
Brief USAGE:
|
||||
../examples/test6 -n <homer|marge|bart|lisa|maggie> [--] [-v] [-h] <1|2
|
||||
|3>
|
||||
|
||||
USAGE:
|
||||
|
||||
../examples/test6 -n <homer,marge,bart,lisa,maggie> [--] [-v] [-h] <1,2,3>
|
||||
|
||||
Where:
|
||||
|
||||
-n <homer,marge,bart,lisa,maggie>, --name <homer,marge,bart,lisa,maggie>
|
||||
(required) (value required) Name to print
|
||||
|
||||
--, --ignore_rest
|
||||
Ignores the rest of the labeled arguments following this flag.
|
||||
|
||||
-v, --version
|
||||
Displays version information and exits.
|
||||
|
||||
-h, --help
|
||||
Displays usage information and exits.
|
||||
|
||||
<1,2,3>
|
||||
(required) (value required) Number of times to print
|
||||
|
||||
|
||||
|
||||
Command description message
|
||||
For complete USAGE and HELP type:
|
||||
../examples/test6 --help
|
||||
|
||||
|
@ -1,29 +1,10 @@
|
||||
PARSE ERROR: Argument: -n (--name)
|
||||
Couldn't find 'mike' in allowed list.
|
||||
|
||||
Brief USAGE:
|
||||
../examples/test7 -n <homer|marge|bart|lisa|maggie> ... [--] [-v] [-h]
|
||||
<1|2|3> ...
|
||||
|
||||
USAGE:
|
||||
|
||||
../examples/test7 -n <homer,marge,bart,lisa,maggie> ... [--] [-v] [-h] <1,2,3> ...
|
||||
|
||||
Where:
|
||||
|
||||
-n <homer,marge,bart,lisa,maggie>, --name <homer,marge,bart,lisa,maggie> (accepted multiple times)
|
||||
(required) (value required) Name to print
|
||||
|
||||
--, --ignore_rest
|
||||
Ignores the rest of the labeled arguments following this flag.
|
||||
|
||||
-v, --version
|
||||
Displays version information and exits.
|
||||
|
||||
-h, --help
|
||||
Displays usage information and exits.
|
||||
|
||||
<1,2,3> (accepted multiple times)
|
||||
(value required) Number of times to print
|
||||
|
||||
|
||||
|
||||
Command description message
|
||||
For complete USAGE and HELP type:
|
||||
../examples/test7 --help
|
||||
|
||||
|
@ -1,29 +1,10 @@
|
||||
PARSE ERROR: Argument: (--times)
|
||||
Couldn't find '6' in allowed list.
|
||||
|
||||
Brief USAGE:
|
||||
../examples/test7 -n <homer|marge|bart|lisa|maggie> ... [--] [-v] [-h]
|
||||
<1|2|3> ...
|
||||
|
||||
USAGE:
|
||||
|
||||
../examples/test7 -n <homer,marge,bart,lisa,maggie> ... [--] [-v] [-h] <1,2,3> ...
|
||||
|
||||
Where:
|
||||
|
||||
-n <homer,marge,bart,lisa,maggie>, --name <homer,marge,bart,lisa,maggie> (accepted multiple times)
|
||||
(required) (value required) Name to print
|
||||
|
||||
--, --ignore_rest
|
||||
Ignores the rest of the labeled arguments following this flag.
|
||||
|
||||
-v, --version
|
||||
Displays version information and exits.
|
||||
|
||||
-h, --help
|
||||
Displays usage information and exits.
|
||||
|
||||
<1,2,3> (accepted multiple times)
|
||||
(value required) Number of times to print
|
||||
|
||||
|
||||
|
||||
Command description message
|
||||
For complete USAGE and HELP type:
|
||||
../examples/test7 --help
|
||||
|
||||
|
@ -1,29 +1,9 @@
|
||||
PARSE ERROR:
|
||||
One or more required arguments missing!
|
||||
|
||||
|
||||
USAGE:
|
||||
|
||||
Brief USAGE:
|
||||
../examples/test1 [-u] -n <string> [--] [-v] [-h]
|
||||
|
||||
Where:
|
||||
|
||||
-u, --upperCase
|
||||
Print in upper case
|
||||
|
||||
-n <string>, --name <string>
|
||||
(required) (value required) Name to print
|
||||
|
||||
--, --ignore_rest
|
||||
Ignores the rest of the labeled arguments following this flag.
|
||||
|
||||
-v, --version
|
||||
Displays version information and exits.
|
||||
|
||||
-h, --help
|
||||
Displays usage information and exits.
|
||||
|
||||
|
||||
|
||||
Command description message
|
||||
For complete USAGE and HELP type:
|
||||
../examples/test1 --help
|
||||
|
||||
|
26
tests/test40.out
Normal file
26
tests/test40.out
Normal file
@ -0,0 +1,26 @@
|
||||
|
||||
USAGE:
|
||||
|
||||
../examples/test1 [-u] -n <string> [--] [-v] [-h]
|
||||
|
||||
|
||||
Where:
|
||||
|
||||
-u, --upperCase
|
||||
Print in upper case
|
||||
|
||||
-n <string>, --name <string>
|
||||
(required) (value required) Name to print
|
||||
|
||||
--, --ignore_rest
|
||||
Ignores the rest of the labeled arguments following this flag.
|
||||
|
||||
-v, --version
|
||||
Displays version information and exits.
|
||||
|
||||
-h, --help
|
||||
Displays usage information and exits.
|
||||
|
||||
|
||||
Command description message
|
||||
|
11
tests/test40.sh
Executable file
11
tests/test40.sh
Executable file
@ -0,0 +1,11 @@
|
||||
#!/bin/sh
|
||||
|
||||
# success
|
||||
../examples/test1 --help > tmp.out 2>&1
|
||||
|
||||
if cmp -s tmp.out test40.out; then
|
||||
exit 0
|
||||
else
|
||||
exit 1
|
||||
fi
|
||||
|
45
tests/test41.out
Normal file
45
tests/test41.out
Normal file
@ -0,0 +1,45 @@
|
||||
|
||||
USAGE:
|
||||
|
||||
../examples/test2 [-f <float>] -i <int> -s <string> [-A] [-C] [-B] [--]
|
||||
[-v] [-h] <string> <string> ...
|
||||
|
||||
|
||||
Where:
|
||||
|
||||
-f <float>, --floatTest <float>
|
||||
(value required) float test
|
||||
|
||||
-i <int>, --intTest <int>
|
||||
(required) (value required) integer test
|
||||
|
||||
-s <string>, --stringTest <string>
|
||||
(required) (value required) string test
|
||||
|
||||
-A, --existTestA
|
||||
tests for the existence of A
|
||||
|
||||
-C, --existTestC
|
||||
tests for the existence of C
|
||||
|
||||
-B, --existTestB
|
||||
tests for the existence of B
|
||||
|
||||
--, --ignore_rest
|
||||
Ignores the rest of the labeled arguments following this flag.
|
||||
|
||||
-v, --version
|
||||
Displays version information and exits.
|
||||
|
||||
-h, --help
|
||||
Displays usage information and exits.
|
||||
|
||||
<string>
|
||||
(required) (value required) unlabeld test
|
||||
|
||||
<string> (accepted multiple times)
|
||||
(value required) file names
|
||||
|
||||
|
||||
this is a message
|
||||
|
11
tests/test41.sh
Executable file
11
tests/test41.sh
Executable file
@ -0,0 +1,11 @@
|
||||
#!/bin/sh
|
||||
|
||||
# success
|
||||
../examples/test2 --help > tmp.out 2>&1
|
||||
|
||||
if cmp -s tmp.out test41.out; then
|
||||
exit 0
|
||||
else
|
||||
exit 1
|
||||
fi
|
||||
|
42
tests/test42.out
Normal file
42
tests/test42.out
Normal file
@ -0,0 +1,42 @@
|
||||
|
||||
USAGE:
|
||||
|
||||
../examples/test3 [-f=<float>] ... [-i=<int>] ... -s=<string> [-B]
|
||||
[--] [-v] [-h] <string> <string> <fileNameString> ...
|
||||
|
||||
|
||||
Where:
|
||||
|
||||
-f <float>, --floatTest <float> (accepted multiple times)
|
||||
(value required) multi float test
|
||||
|
||||
-i <int>, --intTest <int> (accepted multiple times)
|
||||
(value required) multi int test
|
||||
|
||||
-s <string>, --stringTest <string>
|
||||
(required) (value required) string test
|
||||
|
||||
-B, --existTestB
|
||||
exist Test B
|
||||
|
||||
--, --ignore_rest
|
||||
Ignores the rest of the labeled arguments following this flag.
|
||||
|
||||
-v, --version
|
||||
Displays version information and exits.
|
||||
|
||||
-h, --help
|
||||
Displays usage information and exits.
|
||||
|
||||
<string>
|
||||
(required) (value required) unlabeled test one
|
||||
|
||||
<string>
|
||||
(required) (value required) unlabeled test two
|
||||
|
||||
<fileNameString> (accepted multiple times)
|
||||
(value required) file names
|
||||
|
||||
|
||||
this is a message
|
||||
|
11
tests/test42.sh
Executable file
11
tests/test42.sh
Executable file
@ -0,0 +1,11 @@
|
||||
#!/bin/sh
|
||||
|
||||
# success
|
||||
../examples/test3 --help > tmp.out 2>&1
|
||||
|
||||
if cmp -s tmp.out test42.out; then
|
||||
exit 0
|
||||
else
|
||||
exit 1
|
||||
fi
|
||||
|
29
tests/test43.out
Normal file
29
tests/test43.out
Normal file
@ -0,0 +1,29 @@
|
||||
|
||||
USAGE:
|
||||
|
||||
../examples/test4 [-A] [-B] -s <string> [--] [-v] [-h]
|
||||
|
||||
|
||||
Where:
|
||||
|
||||
-A, --sA
|
||||
exist Test B
|
||||
|
||||
-B, --sB
|
||||
exist Test B
|
||||
|
||||
-s <string>, --Bs <string>
|
||||
(required) (value required) string test
|
||||
|
||||
--, --ignore_rest
|
||||
Ignores the rest of the labeled arguments following this flag.
|
||||
|
||||
-v, --version
|
||||
Displays version information and exits.
|
||||
|
||||
-h, --help
|
||||
Displays usage information and exits.
|
||||
|
||||
|
||||
this is a message
|
||||
|
11
tests/test43.sh
Executable file
11
tests/test43.sh
Executable file
@ -0,0 +1,11 @@
|
||||
#!/bin/sh
|
||||
|
||||
# success
|
||||
../examples/test4 --help > tmp.out 2>&1
|
||||
|
||||
if cmp -s tmp.out test43.out; then
|
||||
exit 0
|
||||
else
|
||||
exit 1
|
||||
fi
|
||||
|
44
tests/test44.out
Normal file
44
tests/test44.out
Normal file
@ -0,0 +1,44 @@
|
||||
|
||||
USAGE:
|
||||
|
||||
../examples/test5 {-a <string>|-b <string>} {--eee <string>|--fff
|
||||
<string>|-g <string>} [--ddd] -c <string> [--] [-v] [-h]
|
||||
|
||||
|
||||
Where:
|
||||
|
||||
-a <string>, --aaa <string>
|
||||
(OR required) (value required) or test a
|
||||
-- OR --
|
||||
-b <string>, --bbb <string>
|
||||
(OR required) (value required) or test b
|
||||
|
||||
|
||||
--eee <string>
|
||||
(OR required) (value required) e test
|
||||
-- OR --
|
||||
--fff <string>
|
||||
(OR required) (value required) f test
|
||||
-- OR --
|
||||
-g <string>, --ggg <string>
|
||||
(OR required) (value required) g test
|
||||
|
||||
|
||||
--ddd
|
||||
d test
|
||||
|
||||
-c <string>, --ccc <string>
|
||||
(required) (value required) c test
|
||||
|
||||
--, --ignore_rest
|
||||
Ignores the rest of the labeled arguments following this flag.
|
||||
|
||||
-v, --version
|
||||
Displays version information and exits.
|
||||
|
||||
-h, --help
|
||||
Displays usage information and exits.
|
||||
|
||||
|
||||
this is a message
|
||||
|
11
tests/test44.sh
Executable file
11
tests/test44.sh
Executable file
@ -0,0 +1,11 @@
|
||||
#!/bin/sh
|
||||
|
||||
# success
|
||||
../examples/test5 --help > tmp.out 2>&1
|
||||
|
||||
if cmp -s tmp.out test44.out; then
|
||||
exit 0
|
||||
else
|
||||
exit 1
|
||||
fi
|
||||
|
28
tests/test45.out
Normal file
28
tests/test45.out
Normal file
@ -0,0 +1,28 @@
|
||||
|
||||
USAGE:
|
||||
|
||||
../examples/test6 -n <homer|marge|bart|lisa|maggie> [--] [-v] [-h] <1|2
|
||||
|3>
|
||||
|
||||
|
||||
Where:
|
||||
|
||||
-n <homer|marge|bart|lisa|maggie>, --name <homer|marge|bart|lisa
|
||||
|maggie>
|
||||
(required) (value required) Name to print
|
||||
|
||||
--, --ignore_rest
|
||||
Ignores the rest of the labeled arguments following this flag.
|
||||
|
||||
-v, --version
|
||||
Displays version information and exits.
|
||||
|
||||
-h, --help
|
||||
Displays usage information and exits.
|
||||
|
||||
<1|2|3>
|
||||
(required) (value required) Number of times to print
|
||||
|
||||
|
||||
Command description message
|
||||
|
11
tests/test45.sh
Executable file
11
tests/test45.sh
Executable file
@ -0,0 +1,11 @@
|
||||
#!/bin/sh
|
||||
|
||||
# success
|
||||
../examples/test6 --help > tmp.out 2>&1
|
||||
|
||||
if cmp -s tmp.out test45.out; then
|
||||
exit 0
|
||||
else
|
||||
exit 1
|
||||
fi
|
||||
|
32
tests/test46.out
Normal file
32
tests/test46.out
Normal file
@ -0,0 +1,32 @@
|
||||
|
||||
USAGE:
|
||||
|
||||
../examples/test7 -n <homer|marge|bart|lisa|maggie> ... [--] [-v] [-h]
|
||||
<1|2|3> ...
|
||||
|
||||
|
||||
Where:
|
||||
|
||||
-n <homer|marge|bart|lisa|maggie>, --name <homer|marge|bart|lisa
|
||||
|maggie> (accepted multiple times)
|
||||
(required) (value required) Name to print. This is a long,
|
||||
nonsensical message to test line wrapping. Hopefully it works.
|
||||
|
||||
--, --ignore_rest
|
||||
Ignores the rest of the labeled arguments following this flag.
|
||||
|
||||
-v, --version
|
||||
Displays version information and exits.
|
||||
|
||||
-h, --help
|
||||
Displays usage information and exits.
|
||||
|
||||
<1|2|3> (accepted multiple times)
|
||||
(value required) Number of times to print
|
||||
|
||||
|
||||
Command description message. This is a long multi-line message meant to
|
||||
test line wrapping. This is more text that doesn't really do anything
|
||||
besides take up lots of space that otherwise might be used for something
|
||||
real. That should be enough, don't you think?
|
||||
|
11
tests/test46.sh
Executable file
11
tests/test46.sh
Executable file
@ -0,0 +1,11 @@
|
||||
#!/bin/sh
|
||||
|
||||
# success
|
||||
../examples/test7 --help > tmp.out 2>&1
|
||||
|
||||
if cmp -s tmp.out test46.out; then
|
||||
exit 0
|
||||
else
|
||||
exit 1
|
||||
fi
|
||||
|
@ -1,7 +1,9 @@
|
||||
|
||||
USAGE:
|
||||
|
||||
../examples/test2 [-f <float>] -i <int> -s <string> [-A] [-C] [-B] [--] [-v] [-h] <string> <string> ...
|
||||
../examples/test2 [-f <float>] -i <int> -s <string> [-A] [-C] [-B] [--]
|
||||
[-v] [-h] <string> <string> ...
|
||||
|
||||
|
||||
Where:
|
||||
|
||||
@ -39,6 +41,5 @@ Where:
|
||||
(value required) file names
|
||||
|
||||
|
||||
|
||||
this is a message
|
||||
this is a message
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
#!/bin/sh
|
||||
|
||||
# failure
|
||||
# success
|
||||
../examples/test2 -i 10 -s hello goodbye -hABC > tmp.out 2>&1
|
||||
|
||||
if cmp -s tmp.out test7.out; then
|
||||
|
Loading…
x
Reference in New Issue
Block a user