betamonk has asked for the wisdom of the Perl Monks concerning the following question:
sub require_myconfig_or_config () {.. but it is a really bad hack of course.
if ( $INC{"CPAN/Config.pm"} || _try_loading("CPAN::Config") ) {
return $INC{"CPAN/Config.pm"};
}
elsif ( $INC{"CPAN/MyConfig.pm"} || _try_loading("CPAN::MyConfig", cpan_home())) {
return $INC{"CPAN/MyConfig.pm"};
}
else {
return q{};
}
}
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: More cpan_home for more perl dist
by Anonymous Monk on Dec 13, 2014 at 07:48 UTC | |
|
Re: More cpan_home for more perl dist
by wazat (Monk) on Dec 13, 2014 at 18:02 UTC |