diff options
author | Tar Committer <tar@ocjtech.us> | 2006-12-05 16:52:12 +0000 |
---|---|---|
committer | Tar Committer <tar@ocjtech.us> | 2006-12-05 16:52:12 +0000 |
commit | 1a7c45398738cdb4eaafdc9e0962272f19d54816 (patch) | |
tree | 6863882585a40ef9f65a9bab880a22fdb02c06ab /bin/rancid-cvs.in | |
parent | a0be206eb419f63eeb436631cc91b3456dff006f (diff) | |
download | rancid-1a7c45398738cdb4eaafdc9e0962272f19d54816.tar.gz rancid-1a7c45398738cdb4eaafdc9e0962272f19d54816.tar.xz rancid-1a7c45398738cdb4eaafdc9e0962272f19d54816.zip |
Imported from rancid-2.3.2a6.tar.gz.rancid-2.3.2a6
Diffstat (limited to 'bin/rancid-cvs.in')
-rw-r--r-- | bin/rancid-cvs.in | 29 |
1 files changed, 28 insertions, 1 deletions
diff --git a/bin/rancid-cvs.in b/bin/rancid-cvs.in index fef54b4..24d555a 100644 --- a/bin/rancid-cvs.in +++ b/bin/rancid-cvs.in @@ -1,7 +1,8 @@ #! /bin/sh ## -## $Id: rancid-cvs.in,v 1.18 2006/05/28 16:38:52 heas Exp $ +## $Id: rancid-cvs.in,v 1.19 2006/10/05 04:27:43 heas Exp $ ## +## @PACKAGE@ @VERSION@ ## Copyright (C) 1997-2006 by Terrapin Communications, Inc. ## All rights reserved. ## @@ -28,6 +29,32 @@ # Read in the environment ENVFILE="@sysconfdir@/rancid.conf" +# print a usage message to stderr +pr_usage() { + echo "usage: $0 [-V] [group [group ...]]" >&2; +} + +# command-line options +# -V print version string +if [ $# -ge 1 ] ; then + while [ 1 ] ; do + case $1 in + -V) + echo "@PACKAGE@ @VERSION@" + exit 0 + ;; + -*) + echo "unknown option: $1" >&2 + pr_usage + exit 1 + ;; + *) + break; + ;; + esac + done +fi + . $ENVFILE # Base dir |