X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=lib%2FCatalyst%2FHelper.pm;h=51039cabc5bf05c3eb9081f4a135134bb7fda6d8;hb=255b19ac18c639bc8e5b79d711f6e68c4f77b116;hp=867d5278a8df09125ab38bc8548cfda946055ebd;hpb=fc04b84548e23bf35da1e6bd39fd06c327a496dd;p=catagits%2FCatalyst-Runtime.git diff --git a/lib/Catalyst/Helper.pm b/lib/Catalyst/Helper.pm index 867d527..51039ca 100644 --- a/lib/Catalyst/Helper.pm +++ b/lib/Catalyst/Helper.pm @@ -2,7 +2,6 @@ package Catalyst::Helper; use strict; use base 'Class::Accessor::Fast'; -use Config; use File::Spec; use File::Path; use IO::File; @@ -64,7 +63,7 @@ sub mk_app { $self->{dir} =~ s/\:\:/-/g; $self->{script} = File::Spec->catdir( $self->{dir}, 'script' ); $self->{appprefix} = Catalyst::Utils::appprefix($name); - $self->{startperl} = $Config{startperl}; + $self->{startperl} = '#!/usr/bin/perl -w'; $self->{scriptgen} = $Catalyst::CATALYST_SCRIPT_GEN || 4; $self->{author} = $self->{author} = $ENV{'AUTHOR'} || eval { @{ [ getpwuid($<) ] }[6] } @@ -990,15 +989,21 @@ use Getopt::Long; use Pod::Usage; use Catalyst::PAR; +my $engine = 'CGI'; my $help = 0; +my $par = '[% appprefix %].par'; -GetOptions( 'help|?' => \$help ); +GetOptions( + 'engine=s' => \$engine, + 'help|?' => \$help, + 'par=s' => \$par +); pod2usage(1) if $help; -my $par = Catalyst::PAR->new->package( { - par => $ARGV[0] || '[% appprefix %].par', - engine => $ARGV[1], +Catalyst::PAR->new->package( { + engine => $engine, + par => $par, class => '[% name %]' } ); @@ -1010,10 +1015,12 @@ my $par = Catalyst::PAR->new->package( { =head1 SYNOPSIS -[% appprefix %]_package.pl [par] [engine] +[% appprefix %]_package.pl Options: + -engine engine to use for dependency detection -help display this help and exits + -par name for the par archive Examples: [% appprefix %]_package.pl [% appprefix %].par FastCGI