#!/bin/sh -- A comment mentioning perl, to prevent looping
eval 'exec perl -S -n $0 ${1+"$@"}'
	if 0;

# Perl script to eliminate from 'sccs prt' output those file headers
# for which there are no deltas.  E.g.
# since 931022 | prt_user -v 'ns|lbieber' | prt_brief
#
# THIS SAMPLE PROGRAM IS BEING PROVIDED "AS IS" AND ONLY AS A COURTESY TO
# THE RECIPIENT.  SUN MAKES NO WARRANTY OR REPRESENTATION, EITHER EXPRESS 
# OR IMPLIED WITH RESPECT TO THIS SAMPLE PROGRAM INCLUDING QUALITY, PERF- 
# FORMANCE, FITNESS FOR A PARTICULAR PURPOSE, MERCHANTABILITY, OR NON- 
# INFRINGEMENT.  IN NO EVENT WILL SUN BE LIABLE FOR ANY DIRECT, INDIRECT,  
# SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR  
# INABILITY TO USE THIS SAMPLE PROGRAM.

if (m|^SCCS/|) {
	$hdr=$_;
	$skip=1;
}
elsif ($skip && /^D [0-9]+\.[0-9]+/) {
	$skip=0;
	print $hdr, "\n";
}
print unless $skip;
