From 5261f00f2e12017223f4151d8a416cfacf43410c Mon Sep 17 00:00:00 2001 From: Pedro Vicente Nunes Date: Wed, 31 Oct 2007 12:54:39 -0500 Subject: [svn-r14226] new feature: add a -V version option to hrepack tested: windows, linux --- tools/h5repack/h5repack_main.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/tools/h5repack/h5repack_main.c b/tools/h5repack/h5repack_main.c index 7f9c720..9c8b99f 100644 --- a/tools/h5repack/h5repack_main.c +++ b/tools/h5repack/h5repack_main.c @@ -42,6 +42,7 @@ void usage(void) printf("-o output Output HDF5 File\n"); printf("[-h] Print this message\n"); printf("[-v] Verbose mode\n"); + printf("[-V] Print HDF5 version number and exit\n"); printf("[-n] Use a native HDF5 type when repacking. Default is the file type\n"); printf("[-L, --latest] Use latest version of file format to create groups, datasets and datatypes\n"); printf("[-compact=] Set the maximum number of links to store as header messages in a group\n"); @@ -160,8 +161,11 @@ int main(int argc, char **argv) usage(); exit(0); } - - if (strcmp(argv[i], "-i") == 0) { + else if (strcmp(argv[i], "-V") == 0) { + print_version(progname); + exit(0); + } + else if (strcmp(argv[i], "-i") == 0) { infile = argv[++i]; } else if (strcmp(argv[i], "-o") == 0) { -- cgit v0.12