]> granicus.if.org Git - p11-kit/commitdiff
trust: Print out usage when extract-trust run incorrectly
authorStef Walter <stef@thewalter.net>
Mon, 17 Jun 2013 12:46:03 +0000 (14:46 +0200)
committerStef Walter <stef@thewalter.net>
Mon, 17 Jun 2013 13:22:47 +0000 (15:22 +0200)
Also sorta covers --help and -h usage

tools/p11-kit-extract-trust.in

index b15dd7dbbc7c11f2ccab36552079e9fd56b8595b..c7214e934f7ee2e501669311427a1c9b4622cbce 100755 (executable)
@@ -6,7 +6,12 @@
 # appropriate. In the future this script will be called when the PKCS#11
 # trust module is used to modifiy trust anchors and related data.
 
-echo "p11-kit: the placeholder extract-trust command has not been customized by your distribution."
+if [ $# -ne 0 ]; then
+       echo "usage: p11-kit extract-trust" >&2
+       exit 2
+fi
+
+echo "p11-kit: the placeholder extract-trust command has not been customized by your distribution." >&2
 
 # You can use commands like this to extract data from trust modules
 # into appropriate locations for your distribution.