head	1.3;
access;
symbols;
locks; strict;
comment	@# @;


1.3
date	94.10.27.17.41.10;	author ram;	state Exp;
branches;
next	1.2;

1.2
date	92.02.03.01.46.58;	author ram;	state Exp;
branches;
next	1.1;

1.1
date	91.03.08.19.51.13;	author ram;	state Exp;
branches;
next	;


desc
@Script to frob file header comments.
@


1.3
log
@Flush the "if you want to use this or any part...".
@
text
@#!/bin/csh -f
#
# $Header: /users/ram/RCS/fixheader,v 1.2 1992/02/03 01:46:58 ram Exp ram $

set quotehack = \$"Header: "\$

foreach file ($argv)
	set range = (`fgrep -n ';;; ***********' $file | sed -e '3,$d' -e 's/:.*//'`)
	if ($#range < 2) then
		echo '**********' $file'': Could not find the header comment.
		goto nextfile
	endif
	if ($range[2] > 12) then
		echo '**********' $file'': Large header comment, you deal with it.
		goto nextfile
	endif

	echo fixing $file

	ed $file <<END_OF_ED_STUFF
$range[1],$range[2]d
$range[1]i
;;; **********************************************************************
;;; This code was written as part of the CMU Common Lisp project at
;;; Carnegie Mellon University, and has been placed in the public domain.
;;;
(ext:file-comment
  "$quotehack")
;;;
;;; **********************************************************************
.
w
q
END_OF_ED_STUFF

	nextfile:
end
@


1.2
log
@Used a hack to keep the magic $header string from appearing in the script
so that checking it in doesn't trash it.
@
text
@d3 1
a3 1
# $Header: $
a25 2
;;; If you want to use this code or any part of CMU Common Lisp, please contact
;;; Scott Fahlman or slisp-group@@cs.cmu.edu.
@


1.1
log
@Initial revision
@
text
@d2 2
d5 2
d30 1
a30 1
  "\$Header: \$")
@
