From 1afeddc08f6c61cff204980cfae93d97320ae39f Mon Sep 17 00:00:00 2001 From: dakkar Date: Sat, 14 Jan 2006 17:25:35 +0000 Subject: aggiornamento a nuovo Catalyst, e "permessi di scrittura" (orendo) --- script/bookmarks_create.pl | 23 +++++++++++++++-------- 1 file changed, 15 insertions(+), 8 deletions(-) (limited to 'script/bookmarks_create.pl') diff --git a/script/bookmarks_create.pl b/script/bookmarks_create.pl index 4dceeba..17cba1c 100755 --- a/script/bookmarks_create.pl +++ b/script/bookmarks_create.pl @@ -7,13 +7,19 @@ use Catalyst::Helper; my $help = 0; my $nonew = 0; +my $short = 0; -GetOptions( 'help|?' => \$help, - 'nonew' => \$nonew ); +GetOptions( + 'help|?' => \$help, + 'nonew' => \$nonew, + 'short' => \$short + ); pod2usage(1) if ( $help || !$ARGV[0] ); -my $helper = Catalyst::Helper->new({'.newfiles' => !$nonew}); +my $helper = + Catalyst::Helper->new( { '.newfiles' => !$nonew, short => $short } ); + pod2usage(1) unless $helper->mk_component( 'Bookmarks', @ARGV ); 1; @@ -27,8 +33,9 @@ bookmarks_create.pl - Create a new Catalyst Component bookmarks_create.pl [options] model|view|controller name [helper] [options] Options: - -help display this help and exits - -nonew don't create a .new file where a file to be created exists + -help display this help and exits + -nonew don't create a .new file where a file to be created exists + -short use short types, like C instead of Controller... Examples: bookmarks_create.pl controller My::Controller @@ -49,7 +56,7 @@ Create a new Catalyst Component. Existing component files are not overwritten. If any of the component files to be created already exist the file will be written with a '.new' suffix. -This behaviour can be supressed with the C<-nonew> option. +This behavior can be suppressed with the C<-nonew> option. =head1 AUTHOR @@ -59,7 +66,7 @@ Sebastian Riedel, C Copyright 2004 Sebastian Riedel. All rights reserved. -This library is free software. You can redistribute it and/or modify -it under the same terms as perl itself. +This library is free software, you can redistribute it and/or modify +it under the same terms as Perl itself. =cut -- cgit v1.2.3