#! /bin/ksh # IBM_PROLOG_BEGIN_TAG # This is an automatically generated prolog. # # # # Licensed Materials - Property of IBM # # (C) COPYRIGHT International Business Machines Corp. 1999,2019 # All Rights Reserved # # US Government Users Restricted Rights - Use, duplication or # disclosure restricted by GSA ADP Schedule Contract with IBM Corp. # # IBM_PROLOG_END_TAG # #* CPRY # # sccsid = "@(#)82 1.5 src/rsct/pgs/cmds/hagsns.sh, gsctrl, rsct_rady, rady2035a 11/12/15 16:45:05" #*====================================================================== #* Module Name: hagsns #*====================================================================== basecmd="hagsns" basepath="/opt/rsct/bin" SPMSG=${basepath}/hadspmsg MSGMAPPATH=/opt/rsct/msgmaps export MSGMAPPATH # process the command lines if [[ -z $1 ]]; then # no arguments $SPMSG hagsctrl ha_gs.cat IMsg_hagsns_Usage $basecmd $basecmd $basecmd $basecmd exit fi args="" c_opt="" while getopts ":h:g:s:p:c" opt; do case $opt in h | s | p ) args="$args -${opt} $OPTARG" ;; g ) opt=s args="$args -${opt} $OPTARG" ;; c ) c_opt=1 ;; * ) #${basecmd}: Not a recognized flag: -${OPTARG} $SPMSG hagsctrl ha_gs.cat EMsg_Incorrect_Flag ${basecmd} ${OPTARG} $SPMSG hagsctrl ha_gs.cat IMsg_hagsns_Usage ${basecmd} ${basecmd} ${basecmd} ${basecmd} exit 1 ;; esac done shift $(($OPTIND - 1)) if [[ ! -z $c_opt ]]; then # canonical form exec ${basepath}/${basecmd}_c $args else # locale dependent exec ${basepath}/${basecmd}_nls $args fi