X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=lib%2FCatalyst%2FHelper.pm;h=c31df6755cd280bd08036f0d45c01de6f4670f1b;hb=41ca9ba7190b75d9ee3adebf37188309cad986a4;hp=64dad7066d35af65b61934f69f9efb09533ca5c5;hpb=85f877d72627f8a934999803d3538015f8eca657;p=catagits%2FCatalyst-Runtime.git diff --git a/lib/Catalyst/Helper.pm b/lib/Catalyst/Helper.pm index 64dad70..c31df67 100644 --- a/lib/Catalyst/Helper.pm +++ b/lib/Catalyst/Helper.pm @@ -9,6 +9,7 @@ use IO::File; use FindBin; use Template; use Catalyst; +use Catalyst::Utils; use Catalyst::Exception; my %cache; @@ -61,8 +62,7 @@ sub mk_app { $self->{name} = $name; $self->{dir} = $name; $self->{dir} =~ s/\:\:/-/g; - $self->{appprefix} = lc $self->{dir}; - $self->{appprefix} =~ s/-/_/g; + $self->{appprefix} = Catalyst::Utils::appprefix($name); $self->{startperl} = $Config{startperl}; $self->{scriptgen} = $Catalyst::CATALYST_SCRIPT_GEN || 4; $self->{author} = $self->{author} = $ENV{'AUTHOR'} @@ -217,7 +217,7 @@ sub mk_file { $file .= '.new'; } if ( my $f = IO::File->new("> $file") ) { - $f->binmode; + binmode $f; print $f $content; print qq/created "$file"\n/; return 1; @@ -449,8 +449,8 @@ Sebastian Riedel, C =head1 LICENSE -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 @@ -522,8 +522,8 @@ sub default : Private { =head1 LICENSE -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 @@ -633,8 +633,8 @@ 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 __fastcgi__ @@ -671,8 +671,8 @@ 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 __server__ @@ -759,8 +759,8 @@ 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 __test__ @@ -816,8 +816,8 @@ 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 __create__ @@ -882,8 +882,8 @@ 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 __compclass__ @@ -929,8 +929,8 @@ Catalyst component. =head1 LICENSE -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