#!/usr/bin/sh # IBM_PROLOG_BEGIN_TAG # This is an automatically generated prolog. # # bos720 src/bos/usr/bin/cdat/smit/cdat_init_values.sh 1.2 # # Licensed Materials - Property of IBM # # COPYRIGHT International Business Machines Corp. 2010,2011 # 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 # @(#)35 1.2 src/bos/usr/bin/cdat/smit/cdat_init_values.sh, cdat, bos720 7/15/11 04:16:53 # This command returns the init values (used by smit Create the Repository) # # If cdat is not initialized, the command returns no value PATH=/bin:/sbin:/usr/bin:/usr/sbin [ $# -ne 0 ] && \ echo "Usage: $0" && exit 1 ODMDIR=/etc/objrepos DIR=`/usr/bin/odmget -qattribute=cdat_directory SWservAt | \ awk ' $1=="value" && $3!="\"\"" { gsub( "\"", "", $3) print $3 exit 0 }'` LUSER=`/usr/bin/odmget -qattribute=cdat_user SWservAt | \ awk ' $1=="value" && $3!="\"\"" { gsub( "\"", "", $3) print $3 exit 0 }'` # Default values if necessary [ -z "$DIR" ] && DIR=/cdat [ -z "$LUSER" ] && LUSER=cdat echo "#luser:location" echo "$LUSER:$DIR" exit 0