Amon2::Setup::Flavor - Abstract base class for flavors.
This is an abstract base class for flavors. But you don't need to inherit this class. Amon2 uses duck typing. You should implement only Class->run method.
Class->run
In Amon2, flavor means setup script.
This class provides some useful methods to write setup script.
$flavor->init()
Hook point to initialize module directory.
$flavor->mkpath($dir)
same as `mkdir -p $dir`.
`mkdir -p $dir`
$flavor->write_file($fnametmpl, $template)
$fnametmpl will be replace with the parameters.
$fnametmpl
Generate file using Text::Xslate.
For more details, read the source Luke! Or please write docs...
$flavor->write_file_raw($fname, $content)
Write $content to the $fname.
$content
$fname
To install Amon2, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Amon2
CPAN shell
perl -MCPAN -e shell install Amon2
For more information on module installation, please visit the detailed CPAN module installation guide.