diff --git a/include/tclap/StdOutput.h b/include/tclap/StdOutput.h index 35f7b99..944cff4 100644 --- a/include/tclap/StdOutput.h +++ b/include/tclap/StdOutput.h @@ -143,7 +143,8 @@ inline void StdOutput::failure( CmdLineInterface& _cmd, _shortUsage( _cmd, std::cerr ); std::cerr << std::endl << "For complete USAGE and HELP type: " - << std::endl << " " << progName << " --help" + << std::endl << " " << progName << " " + << Arg::nameStartString() << "help" << std::endl << std::endl; } else diff --git a/tests/Makefile.am b/tests/Makefile.am index 4c0f409..179f80f 100644 --- a/tests/Makefile.am +++ b/tests/Makefile.am @@ -77,7 +77,8 @@ TESTS = test1.sh \ test75.sh \ test76.sh \ test77.sh \ - test78.sh + test78.sh \ + test79.sh EXTRA_DIST = $(TESTS) \ test1.out \ @@ -157,6 +158,7 @@ EXTRA_DIST = $(TESTS) \ test75.out \ test76.out \ test77.out \ - test78.out + test78.out \ + test79.out CLEANFILES = tmp.out diff --git a/tests/runtests.sh b/tests/runtests.sh index e4e64e4..b0ad68f 100644 --- a/tests/runtests.sh +++ b/tests/runtests.sh @@ -2,7 +2,7 @@ let "suc = 0" let "fail = 0" -NUMTEST=67 +NUMTEST=79 for (( tno = 1 ; $tno <= $NUMTEST ; tno = $tno + 1 )); do ./testCheck.sh $tno diff --git a/tests/test63.sh b/tests/test63.sh old mode 100644 new mode 100755 diff --git a/tests/test64.sh b/tests/test64.sh old mode 100644 new mode 100755 diff --git a/tests/test65.sh b/tests/test65.sh old mode 100644 new mode 100755 diff --git a/tests/test66.sh b/tests/test66.sh old mode 100644 new mode 100755 diff --git a/tests/test67.sh b/tests/test67.sh old mode 100644 new mode 100755 diff --git a/tests/test79.out b/tests/test79.out new file mode 100644 index 0000000..9e7b467 --- /dev/null +++ b/tests/test79.out @@ -0,0 +1,9 @@ +PARSE ERROR: + Required argument missing: name + +Brief USAGE: + ../examples/test21 [/r] /n [//] [~~version] [/h] + +For complete USAGE and HELP type: + ../examples/test21 ~~help + diff --git a/tests/test79.sh b/tests/test79.sh new file mode 100755 index 0000000..62f5c02 --- /dev/null +++ b/tests/test79.sh @@ -0,0 +1,11 @@ +#!/bin/sh + +# success +../examples/test21 > tmp.out 2>&1 + +if cmp -s tmp.out $srcdir/test79.out; then + exit 0 +else + exit 1 +fi +