source:
branches/casa-release-4_3/admin/log2req.pl
Last change on this file was 651, checked in by , 19 years ago | |
---|---|
|
|
File size: 468 bytes |
Line | |
---|---|
1 | #!/usr/bin/perl -w |
2 | |
3 | use strict; |
4 | |
5 | use Getopt::Long; |
6 | |
7 | my $purge = 0; |
8 | |
9 | GetOptions('purge'=>\$purge); |
10 | |
11 | my @log = <>; |
12 | my $log = join '', @log; |
13 | |
14 | while ($log =~ /REQUIREMENT:\s*(R.*?):.?E.?N.?D.?R.?E.?Q/sg) { |
15 | $_ = $1; |
16 | s/\n//; |
17 | |
18 | if ($purge) { |
19 | next if (/& Deferred &/); |
20 | next if (/& Obsolete &/); |
21 | next if (/& Done.? &/); |
22 | next if (/& Removed &/); |
23 | } |
24 | |
25 | s/& Done1 & /& Completed &/; |
26 | s/& Done & /& Completed &/; |
27 | |
28 | s/(&[^&]*){2}$//; |
29 | |
30 | print "$_ \\\\\n"; |
31 | } |
Note: See TracBrowser
for help on using the repository browser.