Acme-CramCode

 view release on metacpan or  search on metacpan

CramCode.pm  view on Meta::CPAN

sub encode($){$birthmark. compress shift}
sub decode($){uncompress shift}
sub bm($){$_[0]=~/^$birthmark/s}
open 0 or print "Can't open '$0'\n" and exit;
(my $code=join q//, <0>)=~s/.*^\s*use\s+Acme::CramCode\s*;\n//sm;
do {$code=~s/^$birthmark//;eval decode $code; exit} if bm $code;
open 0, ">$0" or print "Cannot encode '$0'\n" and exit;
print {0} "use Acme::CramCode;\n", encode $code and exit;
1;
__END__
# Below is stub documentation for your module. You better edit it!

=head1 NAME

Acme::CramCode - Compress your code

=head1 SYNOPSIS

    use Acme::CramCode;
    print "Hello, World";



( run in 0.667 second using v1.01-cache-2.11-cpan-de7293f3b23 )