Perl: the Markov chain saw | |
PerlMonks |
use alternate module if pm is not installedby agweih (Initiate) |
on Apr 07, 2021 at 08:46 UTC ( [id://11130939]=perlquestion: print w/replies, xml ) | Need Help?? |
agweih has asked for the wisdom of the Perl Monks concerning the following question: Dear monks, my perlscript should run on different systems (windows, linux) where I don't know which modules are installed and I don't have permission to install modules. Therefore I'm looking for a way to fallback to core modules or my own pm with basic functionality if a module is not installed. My naive thought was using something like this: use JSON || JSON::PP;this does of course not work. What's the best way to do this? thanks in advance! greetings, Toni
Back to
Seekers of Perl Wisdom
|
|