Subject: Re: Changelog -> mailinglist?
To: Jukka Marin <jmarin@pyy.jmp.fi>
From: Rick Byers <rickb@iaw.on.ca>
List: current-users
Date: 08/09/1997 00:02:19
Hi!
I know this thread is extremely old, but I've been away for a month and
now I'm catching up :)
Anyway, I wrote a little perl program that takes the source-changes list
as input (from a procmail filter), and creates a more logical (IMHO)
output. Primarily, this is so I can glance over the subject list to see
if I'm interested (instead of having to look at every message). It's not
perfect (actually, it might not even be better - you be the judge), as it
creates a LOT of messages, but I find it handy. I'm not much of a
perl programmer (but I figured it was the perfect language for the
job), so please forgive the code. Here it is, hope it helps:
#!/local/bin/perl
@ARGV = ('-') unless @ARGV;
foreach $file(@ARGV)
{
$mode = 1;
open(INPUT, $file) || die("Can't open $file");
while( $line = <INPUT> )
{
$line =~ s/\n//;
if( $line =~ /^From / )
{
$path = $line;
if( $mode )
{
printf("\n");
$user='';
$date='';
$update='';
}
$mode = 0; # header mode
}
if( $mode == 10 ) # text mode
{
# if it appears to be the end of the log then it's really mode 1
if( $blankline == 1 && $line =~ /^[a-z]+$/ )
{
$mode = 1;
}
else
{
printf("$line\n");
if( $line =~ /^\s*$/ ) # blank line
{
$blankline=1;
}
else
{
$blankline=0;
}
}
}
else
{
$blankline=0;
}
if( $mode == 0 ) # header mode
{
if( $line =~ /^\s*$/ ) # blank line
{
$mode = 1; # message mode
}
}
elsif( $mode == 1 ) # username line
{
if( $line !~ /^\s*$/ ) # don't print blank lines
{
$user = $line;
$mode++;
}
}
elsif( $mode == 2 ) # date line
{
if( $line !~ /^\s*$/ )
{
$date = $line;
$mode++;
}
}
elsif( $mode == 3 ) # update line
{
if( $line !~ /^\s*$/ )
{
$update=$line;
$update=~ s%^Update of.*/cvsroot/%%;
$mode++; # 'in directory' mode
}
}
elsif( $mode == 4 ) # 'in directory' mode
{
if( $line =~ /^In directory/ )
{
<INPUT>; # absorb next blank line
$mode = 10; # text mode
printf("$path\n");
printf("From: $user <source\@NetBSD.org>\n");
printf("Date: $date\n");
printf("Subject: $update\n");
printf("\n");
}
}
}
close INPUT;
if( $mode != 10 )
{
die ("Unexpected EOF");
}
}
On Sat, 19 Jul 1997, Jukka Marin wrote:
> Dear All,
>
> This may have been asked before, but.. How about posting a list of changes
> to current-users daily? There's this mail which lists all files which
> have changed, but it doesn't actually tell me all that much.. It would be
> interesting to see what has changed (to know when it's worthwile to grab
> the latest source) and just to see what kind of things are being worked on.
>
> How does it sound? I don't run -current at the moment, but I'd still be
> interested in knowing about the current developments.
>
> Thanks,
>
> -jm
>
>
> --
>
> 1503 kHz @ 22:30 EET DST Mon-Fri
>
> ---> http://www.jmp.fi/~jmarin/ <---
>
=========================================================================
Rick Byers Internet Access Worldwide
rickb@iaw.on.ca System Admin, Tech Support
Welland, Ontario, Canada (905)714-1400
http://www.iaw.on.ca/rickb/ http://www.iaw.on.ca/