develooper Front page | perl.perl5.porters | Postings from October 1999

RE: PERL_HEADER env varb: was: Addition to @INC

Thread Previous | Thread Next
From:
Moore, Paul
Date:
October 21, 1999 03:40
Subject:
RE: PERL_HEADER env varb: was: Addition to @INC
Message ID:
714DFA46B9BBD0119CD000805FC1F53BB41594@UKRUX002.rundc.uk.origin-it.com
From: Ed Peschko [mailto:Ed_Peschko@csgsystems.com]
> *sigh*. Ok, your point is well taken, but sometimes I 
> *really* wish that there was something like a PERL_HEADER
> variable in which you could put stuff like 
> this, and which would be included at the beginning of each 
> file. Yes, there would be a performance hit, and yes it
> has the potential to make things non-portable, but its
> really beginning to SUCK to have to add six+ lines at 
> the beginning of every file just to get functionality that is 
> so common but also site-specific. Stuff like:

OK, try:

Site.pm
-------

use strict;
use DBI;
use FindBin;           
use lib $FindBin::Bin; 
use IO;
use Data::Dumper;
use Rebol;
use lib "put site specific libraries here"; 

Put this in @INC (probably sitelib), then do

perl -MSite

or even put -MSite in the PERL5OPT variable...

Paul.

Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About