#!/bin/ksh -p
#
# ident "%W%	%E% Oracle"
#
# Copyright (c) 2010, 2011, Oracle and/or its affiliates. All rights reserved.
#


#
# Usage - prints the usage message
# $1 - the exit code
function Usage {

    cat <<!

Usage:
uttscadm -c -g <group>      # Configure the Sun Ray Connector for Windows Operating Systems
                            # Specify valid groupname to be used. See man page for details.
uttscadm -u                 # Unconfigure the Sun Ray Connector for Windows Operating Systems
uttscadm -r                 # Re-configure the Sun Ray Connector for Windows Operating Systems
uttscadm -h                 # Display this usage message
!
    exit $1

}

print "\nWARNING : /opt/SUNWuttsc/sbin/uttscadm is deprecated in this release and will be removed in subsequent releases..\nPlease use '/opt/SUNWut/sbin/utconfig -c' to configure Sun Ray Windows Connector in the future.\n"

OPTSTR="cuhrg:"
ARGS=""

while getopts $OPTSTR OPT
 do
        case $OPT in
	    c|r|u) ARGS="$ARGS -$OPT";;
				     
            g) ARGS="$ARGS -g $OPTARG";;
		    
	    h) Usage 0;;

	    ?) Usage 1;;
	esac
    done
	
/opt/SUNWuttsc/lib/uttscadm $ARGS

exit $?
