Re: [PATCH 3/3] virt-pki-validate: add --help/--version option

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




----- Original Message -----
From: "Eric Blake" <eblake@xxxxxxxxxx>
To: libvir-list@xxxxxxxxxx
Sent: Monday, August 19, 2013 6:43:15 PM
Subject:  [PATCH 3/3] virt-pki-validate: add --help/--version option

Another program gains --help/--version :)

* tools/virt-pki-validate.in: Add option parsing.  Update
documentation to match.
* tools/Makefile.am (virt-pki-validate): Substitute version.

Signed-off-by: Eric Blake <eblake@xxxxxxxxxx>
---
 tools/Makefile.am          |  5 +++--
 tools/virt-pki-validate.in | 45 ++++++++++++++++++++++++++++++++++++++++++++-
 2 files changed, 47 insertions(+), 3 deletions(-)

...

diff --git a/tools/virt-pki-validate.in b/tools/virt-pki-validate.in
index 5d0453f..87fb230 100755
--- a/tools/virt-pki-validate.in
+++ b/tools/virt-pki-validate.in
@@ -22,6 +22,35 @@
 #
 # Daniel Veillard <veillard@xxxxxxxxxx>
 #
+
+case $1 in
+case $1 in

copy-paste error, double case lines.


+  -h | --h | --he | --hel | --help)
+    cat <<EOF
...

+
+if test $# != 0; then
+    echo "$0: unrecognized argument '$1'" >&2
+    exit 1 ;;

remove ;; here.


ACK with these small fixes.

-- 
1.8.3.1

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list




[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]