#
# Set flags and add plugins for the application
#
-# -Debug : activates the debug mode for very useful log messages
+# -Debug: activates the debug mode for very useful log messages
# Static::Simple: will serve static files from the applications root directory
#
use Catalyst qw/-Debug Static::Simple/;
use Catalyst::Build;
my $build = Catalyst::Build->new(
- create_makefile_pl => 'passthrough',
license => 'perl',
module_name => '[% name %]',
requires => { Catalyst => '5.49' },
use FindBin;
use lib "$FindBin::Bin/../lib";
+my $debug = 0;
my $fork = 0;
my $help = 0;
my $host = undef;
my @argv = @ARGV;
GetOptions(
+ 'debug|d' => \$debug,
'fork' => \$fork,
'help|?' => \$help,
'host=s' => \$host,
if ( $restart ) {
$ENV{CATALYST_ENGINE} = 'HTTP::Restarter';
}
+if ( $debug ) {
+ $ENV{CATALYST_DEBUG} = 1;
+}
require [% name %];
[% appprefix %]_server.pl [options]
Options:
+ -d -debug force debug mode
-f -fork handle each request in a new process
(defaults to false)
-? -help display this help and exits