Mason::Tidy - Engine for masontidy
version 2.56
use Mason::Tidy; my $mc = Mason::Tidy->new(mason_version => 2); my $dest = $mc->tidy($source);
This is the engine used by masontidy - read that first to get an overview.
You can call this API from your own program instead of executing masontidy.
masontidy
These options are the same as the equivalent masontidy command-line options, replacing dashes with underscore (e.g. the --indent-per-block option becomes indent_perl_block here).
--indent-per-block
indent_perl_block
Tidy component source $source and return the tidied result. Throw fatal error if source cannot be tidied (e.g. invalid syntax).
Use Getopt::Long::GetOptions to parse the options in $argv and place params in $params appropriate for passing into the constructor. Returns the return value of GetOptions.
Getopt::Long::GetOptions
GetOptions
Jonathan Swartz <swartz@pobox.com>
This software is copyright (c) 2011 by Jonathan Swartz.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.
To install Mason::Tidy, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Mason::Tidy
CPAN shell
perl -MCPAN -e shell install Mason::Tidy
For more information on module installation, please visit the detailed CPAN module installation guide.