#!/usr/local/bin/perl # $Id: fixid,v 1.1 1999/01/03 04:00:20 sybalsky Exp $ # #************************************************************************/ #* */ #* (C) Copyright 1999 Venue. All Rights Reserved. */ #* Manufactured in the United States of America. */ #* */ #* The contents of this file are proprietary information */ #* belonging to Venue, and are provided to you under license. */ #* They may not be further distributed or disclosed to third */ #* parties without the specific permission of Venue. */ #* */ #************************************************************************/ ###################################################################### # # # FIXID -- fix up the ID comment and static in source files # # # ###################################################################### $file = shift; chomp $file; printf "File is %s.\n", $file; open IN, "<" . $file; open OUT, ">".$file.".new"; ## Copy the first two lines of the file (ID comment & static) $line = ; printf OUT "%s", $line; $line = ; printf OUT "%s", $line; ## Now copy the rest of the file, omitting any line with a (#) ## in it (the likeliest ID Comment/static contents for SCCS. $line = ; while ( $line ) { if ( $line =~ /\(#\)/ ) { printf "Omitting line: %s", $line; } else { printf OUT "%s", $line; } $line = ; } close IN; close OUT; ## Save the original file, and put the "fixed" on in its place. `mv $file $file.orig`; `mv $file.new $file`;