From 5ca971a18a708341dd49f27c23fec40ea4342d13 Mon Sep 17 00:00:00 2001 From: Bruce Momjian Date: Thu, 16 Dec 1999 20:10:02 +0000 Subject: Hi, I sending promised patch with: * getopt_long() - for pg_dump (portable) * and "Usage: " changes in scripts in src/bin/ - this changes are cosmetic only, not change any feature ...etc. All PostgreSQL routines (scripts) support now long options and help's output is alike for all scripts and all support -? or --help. Karel Karel Zak http://home.zf.jcu.cz/~zakkr/ --- src/bin/scripts/createlang.sh | 25 +++++++++++++++++-------- 1 file changed, 17 insertions(+), 8 deletions(-) (limited to 'src/bin/scripts/createlang.sh') diff --git a/src/bin/scripts/createlang.sh b/src/bin/scripts/createlang.sh index 2b39eaa7125..18c7c1baa71 100644 --- a/src/bin/scripts/createlang.sh +++ b/src/bin/scripts/createlang.sh @@ -8,7 +8,7 @@ # # # IDENTIFICATION -# $Header: /cvsroot/pgsql/src/bin/scripts/Attic/createlang.sh,v 1.2 1999/12/07 22:41:44 momjian Exp $ +# $Header: /cvsroot/pgsql/src/bin/scripts/Attic/createlang.sh,v 1.3 1999/12/16 20:10:02 momjian Exp $ # #------------------------------------------------------------------------- @@ -51,7 +51,6 @@ do case "$1" in --help|-\?) usage=t - break ;; --list|-l) list=t @@ -127,12 +126,22 @@ do shift done - - -if [ "$usage" ]; then - echo "Usage: $CMDNAME [-h server] [-p port] [-U username] [-d dbname] \\" - echo " [-L|--pglib PGLIB] [langname [dbname]]" - exit 0 +if [ "$usage" ]; then + echo "" + echo "Usage: $CMDNAME [options] [langname [dbname]]" + echo "" + echo " -h HOSTNAME, --host=HOSTNAME " + echo " -p PORT, --port=PORT " + echo " -U USERNAME, --username=USERNAME " + echo " -W, --password " + echo " -d DBNAME, --database=DBNAME " + echo " -e, --echo " + echo " -q, --quiet " + echo " -D PATH, --location=PATH " + echo " -L PGLIB --pglib=PGLIB " + echo " -?, --help " + echo "" + exit 1 fi if [ "$list" ]; then -- cgit v1.2.3