Changeset 8953 for lang/perl/App-Starter
- Timestamp:
- 04/06/08 09:02:15 (8 months ago)
- Location:
- lang/perl/App-Starter/trunk
- Files:
-
- 3 modified
-
bin/app-starter-catalyst.pl (modified) (3 diffs)
-
bin/app-starter.pl (modified) (3 diffs)
-
lib/App/Starter.pm (modified) (7 diffs)
Legend:
- Unmodified
- Added
- Removed
-
lang/perl/App-Starter/trunk/bin/app-starter-catalyst.pl
r8492 r8953 1 #!/usr/bin/perl 1 #!/usr/bin/perl 2 2 3 3 use strict; … … 17 17 app-starter-catalyst.pl - App::Starter script file. 18 18 19 =head1 SYNOPS YS19 =head1 SYNOPSIS 20 20 21 21 app-starter-catalyst.pl --template --name MyApp … … 35 35 =cut 36 36 37 38 -
lang/perl/App-Starter/trunk/bin/app-starter.pl
r8492 r8953 1 #!/usr/bin/perl 1 #!/usr/bin/perl 2 2 3 3 use strict; … … 20 20 app-script.pl - App::Starter script file. 21 21 22 =head1 SYNOPS YS22 =head1 SYNOPSIS 23 23 24 24 app-script.pl --config conf/your-config.yml --name my_application … … 38 38 =cut 39 39 40 41 -
lang/perl/App-Starter/trunk/lib/App/Starter.pm
r8498 r8953 39 39 my $conf_file = ''; 40 40 if (-e File::Spec->catfile( $ENV{HOME}, '/.app-starter/conf', $config->{template} . '.yml' ) ) { 41 $conf_file = File::Spec->catfile( $ENV{HOME}, '/.app-starter/conf', $config->{template} . '.yml' ) ;41 $conf_file = File::Spec->catfile( $ENV{HOME}, '/.app-starter/conf', $config->{template} . '.yml' ) ; 42 42 } 43 43 else { 44 $conf_file = File::Spec->catfile( $ENV{HOME}, '/.app-starter/conf', $config->{template} . '.yaml' );44 $conf_file = File::Spec->catfile( $ENV{HOME}, '/.app-starter/conf', $config->{template} . '.yaml' ); 45 45 } 46 46 … … 112 112 if ( -d $name ) { 113 113 $name =~ s/$from//; 114 $name =~ s /^\///;114 $name =~ s{^/}{}; 115 115 push @{ $self->{dirs} }, $name; 116 116 } 117 117 else { 118 118 $name =~ s/$from//; 119 $name =~ s /^\///;119 $name =~ s{^/}{}; 120 120 push @{ $self->{files} }, $name; 121 121 } … … 129 129 App::Starter - App Starter 130 130 131 =head1 SYN PSYS131 =head1 SYNOPSIS 132 132 133 133 … … 136 136 # or 137 137 # from = 'tmp/a' , replace => { module => 'MyApp' } overwrite config.yml setting. 138 my $app = App::Starter->new( { config => ' /home/tomyhero/work/App-Starter/conf/config.yml' ,from => '/tmp/a' , name => 'my_app' , replace => { module => 'MyApp' } } )->create;139 140 # or even you can use ~/.app-sterter 138 my $app = App::Starter->new( { config => '/home/tomyhero/work/App-Starter/conf/config.yml' , from => '/tmp/a' , name => 'my_app' , replace => { module => 'MyApp' } } )->create; 139 140 # or even you can use ~/.app-sterter 141 141 142 142 #~/.app-starter … … 154 154 =head1 DESCRIPTION 155 155 156 you can start your application quickly once you craete skelton with this module. This module only does is rename key to value. in your template file , you can set like this [% key_name %]156 you can start your application quickly once you craete skelton with this module. This module only does is rename key to value. in your template file, you can set like this [% key_name %] 157 157 which replace with value you set in config. and also you can use __key_name__ format as file or directory name which replace as rule you set at config 158 158 … … 165 165 - \.svn 166 166 - \.cvs 167 replace : # rule for replace key : value 167 replace : # rule for replace key : value 168 168 module : MyApp 169 169 … … 180 180 =head1 AUTHOR 181 181 182 Tomohiro Teranishi <tomohiro.teranishi@gmail.com>182 Tomohiro Teranishi <tomohiro.teranishi@gmail.com> 183 183 184 184 dann
![(please configure the [header_logo] section in trac.ini)](/share/chrome/site/your_project_logo.png)