This will check whether a module is installed....But how to install it from the script if it is not installed??BEGIN { eval('use abc::fdj'); if($@) { die "You need to install ModuleName...\n" if $@; #`perl -MCPAN -e shell | install abc::def`; # `install abc::def`; } else { print "The module is installed\n"; } }
In reply to Re^2: Checking and installing a perl module
by Anonymous Monk
in thread Checking and installing a perl module
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |