If you have a package called "Module" defined in "Module.pm" in the working directory, all you have to do is say "use Module;" from your script. The script's working directory is already in @INC so you don't need to add a reference to elsewhere via "use lib", though that's a great way to keep all your common code together in one place and reference it from everywhere.
Yep. icrf is right.
If @INC doesnt include the current working directory and the module cant be found, perl is nice enough to tell you where your module should be.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.