X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=catagits%2FCatalyst-Runtime.git;a=blobdiff_plain;f=lib%2FCatalyst%2FHelper.pm;h=6f0feb22c5fcfb576f17d626bbca71afd40bfb3b;hp=ee6f6f9a5315fec8fb170baec723e0a739327128;hb=ddb46924d609e98c91cbefa351b0de4f5433c97c;hpb=e8bf1b2d56f1855a8392c67c164f5eb06e28d2f1 diff --git a/lib/Catalyst/Helper.pm b/lib/Catalyst/Helper.pm index ee6f6f9..6f0feb2 100644 --- a/lib/Catalyst/Helper.pm +++ b/lib/Catalyst/Helper.pm @@ -62,6 +62,8 @@ sub mk_app { $self->{dir} =~ s/\:\:/-/g; $self->{startperl} = $Config{startperl}; $self->{scriptgen}=$CATALYST_SCRIPT_GEN; + $self->{author}=$self->{author} = $ENV{'AUTHOR'} || + @{[getpwuid($<)]}[6]; $self->_mk_dirs; $self->_mk_appclass; $self->_mk_makefile; @@ -87,6 +89,8 @@ sub mk_component { my $self = shift; my $app = shift; $self->{app} = $app; + $self->{author}=$self->{author} = $ENV{'AUTHOR'} || + @{[getpwuid($<)]}[6]; $self->{base} = File::Spec->catdir( $FindBin::Bin, '..' ); unless ( $_[0] =~ /^model|m|view|v|controller|c\$/i ) { my $helper = shift; @@ -360,6 +364,11 @@ All helper classes should be under one of the following namespaces. Catalyst::Helper::View:: Catalyst::Helper::Controller:: +=head1 NOTE + +The helpers will read author name from /etc/passwd by default. +To override, please export the AUTHOR variable. + =head1 SEE ALSO L, L, L, @@ -413,7 +422,7 @@ Very nice application. =head1 AUTHOR -Clever guy +[%author%] =head1 LICENSE @@ -749,7 +758,7 @@ Very nice component. =head1 AUTHOR -Clever guy +[%author%] =head1 LICENSE