in reply to how to get a module to work in a specific directory

Can't you just use

use lib '/directory/containing/your/pm'; use testmodule;

or

BEGIN { require 'path/to/testmodule.pm'; your::package::name->import; }

see lib or use for more information


Unless I state otherwise, all my code runs with strict and warnings