3 eval 'exec /usr/bin/perl -w -S $0 ${1+"$@"}'
4 if 0; # not running under some shell
10 eval " use Catalyst::Devel 1.0; ";
14 To use the Catalyst development tools including catalyst.pl and the
15 generated script/myapp_create.pl you need Catalyst::Helper, which is
16 part of the Catalyst-Devel distribution. Please install this via a
17 vendor package or by running one of -
19 perl -MCPAN -e 'install Catalyst::Devel'
20 perl -MCPANPLUS -e 'install Catalyst::Devel'
35 'force|nonew' => \$force,
36 'makefile' => \$makefile,
37 'scripts' => \$scripts,
40 pod2usage(1) if ( $help || !$ARGV[0] );
42 my $helper = Catalyst::Helper->new(
44 '.newfiles' => !$force,
45 'makefile' => $makefile,
46 'scripts' => $scripts,
50 # Pass $ARGV[0] for compatibility with old ::Devel
51 pod2usage(1) unless $helper->mk_app( $ARGV[0] );
58 catalyst - Bootstrap a Catalyst application
62 catalyst.pl [options] application-name
64 'catalyst.pl' creates a skeleton for a new application, and allows you to
65 upgrade the skeleton of your old application.
68 -force don't create a .new file where a file to be created exists
69 -help display this help and exit
70 -makefile only update Makefile.PL
71 -scripts only update helper scripts
73 application-name must be a valid Perl module name and can include "::",
74 which will be converted to '-' in the project name.
81 To upgrade your app to a new version of Catalyst:
82 catalyst.pl -force -scripts MyApp
87 The C<catalyst.pl> script bootstraps a Catalyst application, creating a
88 directory structure populated with skeleton files.
90 The application name must be a valid Perl module name. The name of the
91 directory created is formed from the application name supplied, with double
92 colons replaced with hyphens (so, for example, the directory for C<My::App> is
95 Using the example application name C<My::App>, the application directory will
96 contain the following items:
102 a skeleton README file, which you are encouraged to expand on
106 a changes file with an initial entry for the creation of the application
110 Makefile.PL uses the C<Module::Install> system for packaging and distribution
115 contains the application module (C<My/App.pm>) and
116 subdirectories for model, view, and controller components (C<My/App/M>,
117 C<My/App/V>, and C<My/App/C>).
121 root directory for your web document content. This is left empty.
125 a directory containing helper scripts:
129 =item C<myapp_create.pl>
131 helper script to generate new component modules
133 =item C<myapp_server.pl>
135 runs the generated application within a Catalyst test server, which can be
136 used for testing without resorting to a full-blown web server configuration.
138 =item C<myapp_cgi.pl>
140 runs the generated application as a CGI script
142 =item C<myapp_fastcgi.pl>
144 runs the generated application as a FastCGI script
146 =item C<myapp_test.pl>
148 runs an action of the generated application from the comand line.
158 The application module generated by the C<catalyst.pl> script is functional,
159 although it reacts to all requests by outputting a friendly welcome screen.
163 Neither C<catalyst.pl> nor the generated helper script will overwrite existing
164 files. In fact the scripts will generate new versions of any existing files,
165 adding the extension C<.new> to the filename. The C<.new> file is not created
166 if would be identical to the existing file.
168 This means you can re-run the scripts for example to see if newer versions of
169 Catalyst or its plugins generate different code, or to see how you may have
170 changed the generated code (although you do of course have all your code in a
171 version control system anyway, don't you ...).
175 L<Catalyst::Manual>, L<Catalyst::Manual::Intro>
179 Catalyst Contributors, see Catalyst.pm
183 This library is free software, you can redistribute it and/or modify it under
184 the same terms as Perl itself.