Commit | Line | Data |
cc999ce2 |
1 | #!/usr/bin/env perl |
2 | |
d1014540 |
3 | use FindBin qw/$Bin/; |
4 | |
5 | ## because this is a test |
6 | use lib "$Bin/../../../lib"; |
7 | use Catalyst::ScriptRunner; |
8 | Catalyst::ScriptRunner->run('TestApp','Create'); |
9 | |
cc999ce2 |
10 | |
11 | 1; |
12 | |
13 | =head1 NAME |
14 | |
15 | testapp_create.pl - Create a new Catalyst Component |
16 | |
17 | =head1 SYNOPSIS |
18 | |
19 | testapp_create.pl [options] model|view|controller name [helper] [options] |
20 | |
21 | Options: |
22 | -force don't create a .new file where a file to be created exists |
23 | -mechanize use Test::WWW::Mechanize::Catalyst for tests if available |
24 | -help display this help and exits |
25 | |
26 | Examples: |
27 | testapp_create.pl controller My::Controller |
28 | testapp_create.pl -mechanize controller My::Controller |
29 | testapp_create.pl view My::View |
30 | testapp_create.pl view MyView TT |
31 | testapp_create.pl view TT TT |
32 | testapp_create.pl model My::Model |
33 | testapp_create.pl model SomeDB DBIC::Schema MyApp::Schema create=dynamic\ |
34 | dbi:SQLite:/tmp/my.db |
35 | testapp_create.pl model AnotherDB DBIC::Schema MyApp::Schema create=static\ |
36 | dbi:Pg:dbname=foo root 4321 |
37 | |
38 | See also: |
39 | perldoc Catalyst::Manual |
40 | perldoc Catalyst::Manual::Intro |
41 | |
42 | =head1 DESCRIPTION |
43 | |
44 | Create a new Catalyst Component. |
45 | |
46 | Existing component files are not overwritten. If any of the component files |
47 | to be created already exist the file will be written with a '.new' suffix. |
48 | This behavior can be suppressed with the C<-force> option. |
49 | |
50 | =head1 AUTHORS |
51 | |
52 | Catalyst Contributors, see Catalyst.pm |
53 | |
54 | =head1 COPYRIGHT |
55 | |
56 | This library is free software. You can redistribute it and/or modify |
57 | it under the same terms as Perl itself. |
58 | |
59 | =cut |