home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Usenet 1994 October
/
usenetsourcesnewsgroupsinfomagicoctober1994disk2.iso
/
misc
/
volume8
/
libhoward
/
part08
/
cia.b
< prev
next >
Wrap
Text File
|
1989-10-01
|
1KB
|
66 lines
# cia - Check in arguments to RCS
#
# $Header: cia.b,v 1.3 89/09/23 14:06:03 howard Exp $
#
# Copyright 1989 Howard Lee Gayle
# This file is written in the ISO 8859/1 character set.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License version 1,
# as published by the Free Software Foundation.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
#
# Shell variables:
# c - flag to check out again
# f - steps through files
# r - RCS file
# u - usage string
CMDNAME=cia
export CMDNAME
u="Usage: $CMDNAME [-u] file..."
if [ "x$1" = x-u ]
then
c=1
shift
fi
if [ $# -eq 0 ]
then
echo "$u" 1>&2
exit 1
fi
if [ ! -d RCS ]
then
echo "$CMDNAME: no RCS directory" 1>&2
exit 1
fi
for f
do
if [ -r "$f" ]
then
r="RCS/$f,v"
if [ -f "$r" ]
then
echo "$CMDNAME: $r: RCS file already exists" 1>&2
else
ci "$f" "$r" && rcs -L "$r"
if [ $c ]
then
co "$f"
fi
fi
else
echo "$CMDNAME: $f: file not readable" 1>&2
fi
done