[Catalyst-dev] PATCH for Catalyst::Plugin::ConfigLoader
Gareth Kirwan
gbjk at thermeon.com
Wed Aug 22 20:25:05 GMT 2007
> Jason Kohles wrote:
> > On Aug 21, 2007, at 9:05 PM, Jonathan Rockway wrote:
> >
> >> Sorry to hijack this thread... but it reminded me...
> something I've been
> >> wanting for a while is:
> >>
> >> $c->config->{substitutions} = {
> >> foo => sub { bar($_[0]) . baz($_[1]) }
> >> ...
> >> }
> >
> > sub config_substitutions {
> > my $c = shift;
> > for ( @_ ) {
> > s{__HOME__}{ $c->path_to( '' ) }e;
> > s{__path_to\((.+)\)__}{ $c->path_to( split( '/', $1 ) ) }e;
> > }
> > }
>
> I've committed a patch that combines the above two options [1].
>
> -Brian
Fantastic. And yet ... ;o)
More information about the Catalyst-dev
mailing list