Acme::Echo - Display perl statements before, after, and/or during execution
Version 0.02
use Acme::Echo qw/lines/; print "hello world\n"; print "blah\n"; no Acme::Echo; print "foo\n"; my $srclog; BEGIN{ open $srclog, '>', "srclog.txt" or die; } use Acme::Echo 'after', src_fmt=>"This code was just executed==>\n%s\n<==\n", fh=>$srclog; ...
One or more of before/after/lines may be specified. At least one shoud be specified (pointless otherwise). The others are optional.
Print out the entire code source before execution.
Print out the entire code source after execution.
Print out each line of source right before its execution (note Limitations below).
The sprintf format used for printing lines in lines mode. Defaults to "%s\n".
The sprintf format used for printing the whole source in before/after modes. Defaults to "==>\n%s\n<==\n".
A filehandle to print to. Defaults to *STDOUT.
The lines mode doesn't currently support compound or sub statements.
line numbering for the blocks for before and after modes
More thorough test suite, including code that uses loops, subs, if/else ladders, closures, etc.
make the PPI loading dynamic; and make PPI an optional prereq (And SKIP in tests); So that can use before and after modes w/o having PPI installed.
David Westbrook (davidrw), <dwestbrook at gmail.com>
<dwestbrook at gmail.com>
Please report any bugs or feature requests to bug-acme-echo at rt.cpan.org, or through the web interface at http://rt.cpan.org/NoAuth/ReportBug.html?Queue=Acme-Echo. I will be notified, and then you'll automatically be notified of progress on your bug as I make changes.
bug-acme-echo at rt.cpan.org
I'm also available by email or via '/msg davidrw' on http://perlmonks.org.
You can find documentation for this module with the perldoc command.
perldoc Acme::Echo
You can also look for information at:
AnnoCPAN: Annotated CPAN documentation
http://annocpan.org/dist/Acme-Echo
CPAN Ratings
http://cpanratings.perl.org/d/Acme-Echo
RT: CPAN's request tracker
http://rt.cpan.org/NoAuth/Bugs.html?Dist=Acme-Echo
Search CPAN
http://search.cpan.org/dist/Acme-Echo
Samy_rio for his post (http://perlmonks.org/?node_id=568087) that inspired this.
Copyright 2006 David Westbrook, all rights reserved.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
To install Acme::Echo, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Acme::Echo
CPAN shell
perl -MCPAN -e shell install Acme::Echo
For more information on module installation, please visit the detailed CPAN module installation guide.