# FILE: SCcdc	Change Delta Commentary
#
# SYNOPSIS:	SCcdc -r<release> -c<comment_file> [file...]
#============================================================
#
# PARSE COMMAND LINE
while ("$1" =~ -*)
	switch ($1)
	case -r*:
		if ("$1" =~ *.*) then
			echo "Specify release WITHOUT level"
			exit (1)
		endif
		set version = $1.1
		shift
		breaksw
	case -c*:
		set commt_file = `echo $1 | colrm 1 2`
		shift
		breaksw
	default:
		echo "Invalid argument $1"
		exit (1)
	endsw
end
#
if ((! $?version) || (! $?commt_file)) then
	echo "Usage: SCcdc -r<release> -c<comment_file> [file...]"
	exit (1)
endif
#
# GENERATE CORRECT FILE NAME PARAMETERS
if ($#argv == 0) then
	set fils = SCCS
else
	set fils = ""
	foreach i ($argv)
		set fils = "$fils SCCS/s.$i"
	end
endif
#
# CHANGE THE DELTA COMMENTARY
/usr/sccs/cdc $version $fils <$commt_file
