note
tomfahle
<p>
Have a look at <a href="http://search.cpan.org/perldoc?PPI::Document">PPI::Document</a>, too:
</p>
<code>
#!/usr/bin/perl
use strict;
use warnings;
# Straight from the documention
use PPI;
# Load a document from a file
my $Document = PPI::Document->new('My/Module.pm');
# Strip out comments
$Document->prune('PPI::Token::Comment');
# Strip out Pod
$Document->prune('PPI::Token::Pod');
# Save the file
$Document->save('My/Module.pm.stripped');
</code>
<p>
Hth, Thomas
</p>
<p>
Udate: Added code to strip Pod
</p>
839616
839656