No problem. I like to first add the path where the module
lies to @INC rather than assume the module will
always be in the same directory as the executing script.
Something like:
use lib '/path/to/my/module';
use module;
require is not deprecated, but i use
use 99.99% of the time. Follow those
links or read about those two pragmas with:
perldoc -f use
perldoc -f require
If you want to install Geography::Countries, you
should read A Guide to Installing Modules.
jeffa
L-LL-L--L-LL-L--L-LL-L--
-R--R-RR-R--R-RR-R--R-RR
B--B--B--B--B--B--B--B--
H---H---H---H---H---H---
(the triplet paradiddle with high-hat)
| [reply] [d/l] |
A couple of ways...
- Put the module in the directory where the script runs
- Add use lib '/path/to/my/modules' before using any of your modules
- Update: Set the environment variable PERLLIB or PERL5LIB to the location of your modules
90% of every Perl application is already written. ⇒ | dragonchild |
| [reply] [d/l] |
| [reply] |