Ricardo SIGNES schreef:
> * Ken Williams <[EMAIL PROTECTED]> [2008-11-03T09:49:01]
>> What I would like to do next is make it more of a pure pass-through,
>> so that anything S::L knows about can be fed to M::B. That might
>> depend on having a registry in S::L, or it might mean an author could
>> specify a class name directly, possibly omitting the
>> "Software::License::" prefix.
>
> What I do in Dist::Zilla's license bit is rewrite '=Foo::Bar' to
> 'Foo::Bar' and 'Foo::Bar' to 'Software::License::Foo::Bar'
>
> That allows people to specify a license class in the normal namespace
> or, if they must, =MyCorp::License::MCPL.
>
> I'd love to avoid having a registry, because it will allow people to
> specify
> their own internal license and have all the code generate the right
> files.
> They don't even need to bundle the library -- heck they don't even
> NEED to
> release it to CPAN, because M::B will create the right LICENSE file.
> (...and
> if they do release it, that's great too!)
Suggestion for a core license.pm:
package license;
$LICENSE = "perl";
1;
sub import {
eval sprintf q/*%s::LICENSE=\\"%s"/,
scalar caller,
@_ == 2 ? $_[1] : join ",", @_[1..$#_];
1;
}
__END__
(and C<use license ... ;> should be compiled away unless at
distribution-time)
--
Affijn, Ruud
"Gewoon is een tijger."