Jeff Abrahamson on 30 Jul 2007 08:52:13 -0000


[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

Re: [PLUG] regex


On Mon, Jul 30, 2007 at 10:47:11AM +0200, Jeff Abrahamson wrote:
> I've attached the perl script that I wrote in two minutes.

This time I even attached it. ;-)

-- 
 Jeff

 Jeff Abrahamson  <http://jeff.purple.com/>
 phone: +33 06 21.83.26.20           (From U.S.: 011-33-6-2183-2620)
 GPG fingerprint: 1A1A BA95 D082 A558 A276  63C6 16BF 8C4C 0D1D AE4B
#!/usr/bin/perl -w

use strict;

my $pdf;
{
    undef $/;
    $pdf = <>;
}

$pdf =~ s/^.*?Contents\(//s;
$pdf =~ s/\).*?Contents\(/\n\n\n/sg;
$pdf =~ s/\).*$//s;
print $pdf, "\n";
		       

Attachment: signature.asc
Description: Digital signature

___________________________________________________________________________
Philadelphia Linux Users Group         --        http://www.phillylinux.org
Announcements - http://lists.phillylinux.org/mailman/listinfo/plug-announce
General Discussion  --   http://lists.phillylinux.org/mailman/listinfo/plug