Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

Re: Using File::ShareDir in development

by Anonymous Monk
on Apr 18, 2011 at 11:08 UTC ( #899921=note: print w/ replies, xml ) Need Help??


in reply to Using File::ShareDir in development

Given this, does anyone know how I would access the shared files in development using the same code that will be deployed?

Install the module
set PERL_MB_OPT=--install_base /home/user/devstuff set PERL_MM_OPT=INSTALL_BASE=/home/user/devstuff
cpanp i Mo::Dule
cpan  Mo::Dule
perl Build.PL --install_base /home/user/devstuff
perl Makefile.PL  INSTALL_BASE=/home/user/devstuff
Then use it
set PERL5LIB=/home/user/devstuff/lib/perl5
use lib '/home/user/devstuff/lib/perl5';


Comment on Re: Using File::ShareDir in development
Select or Download Code
Re^2: Using File::ShareDir in development
by Anonymous Monk on May 08, 2014 at 13:42 UTC
    Except this doesn't actually solve the problem. If you are writing tests that rely on finding files in the shared directory, when an end user attempts to install the module, they are going to get errors on these tests that the shared directory cannot be found. The tests are going to fail until the module is installed. So unless you write specific instructions that the user needs to force install before testing... A clean solution that allows you to develop and install with no special instructions is ideal.

      Except ... blah ...

      Development doesn't imply "tests that rely on sharedir" :) its perfectly possible to develop this way ... sure its no File::Share (or the other longer named module) but not a big deal :)

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://899921]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others lurking in the Monastery: (12)
As of 2014-09-19 11:15 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    How do you remember the number of days in each month?











    Results (135 votes), past polls