Catalyst::Plugin::CommandLine - Catalyst plugin to make $c available also for scripts.
# in MyCatalystApp.pm use Catalyst qw( CommandLine ); # in a script use MyCatalystApp; my $c = MyCatalystApp->commandline; $c->stash->{ ... $c->model( ... $c->controller( ... $c->view( ...
Use this module if you need to have access to the Catalyst controllers or models from command line script.
Will setup $c so that it could be used in the script.
Setups stash, request, response, sessionid.
Returns true/false if catalyst is running in commandline mode.
Jozef Kutej - <jkutej@cpan.org>
Copyright (C) 2007 by Jozef Kutej
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.8.8 or, at your option, any later version of Perl 5 you may have available.
To install Catalyst::Plugin::CommandLine, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Catalyst::Plugin::CommandLine
CPAN shell
perl -MCPAN -e shell install Catalyst::Plugin::CommandLine
For more information on module installation, please visit the detailed CPAN module installation guide.