PrePAN

Sign in to PrePAN

Carton::Include A module to automatically include the nearest local/ dir

Author
akarelas@github
Date
URL
Status
In Review
Good

Synopsis

#!/usr/bin/env perl

use Carton::Include;
use ...;

Description

When I want to execute script that uses a cpanfile & Carton, I have to type "carton exec ./script.pl" in order to execute it (in order to include the nearest local/ directory in @INC). By creating Carton::Include, and using this module inside my scripts, I can have them automatically search for the nearest local/ directory up the tree and "use lib" that, so I can then execute my script by typing only ./script.pl

Comments

Please sign up to post a review.