Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>Reading through perldoc perlrun it looks like you are looking for what is talked about in the -f option: </p> <blockquote> <p>-f</p> <p>Disable executing $Config{sitelib}/sitecustomize.pl at startup.</p> <p>Perl can be built so that it by default will try to execute $Config{sitelib}/sitecustomize.pl at startup (in a BEGIN block). This is a hook that allows the sysadmin to customize how Perl behaves. It can for instance be used to add entries to the @INC array to make Perl find modules in non-standard locations.</p> <p>Perl actually inserts the following code:</p> <pre><code>BEGIN { do { local $!; -f "$Config{sitelib}/sitecustomize.pl"; } &amp;&amp; do "$Config{sitelib}/sitecustomize.pl"; } </code></pre> <p>Since it is an actual do (not a require), sitecustomize.pl doesn't need to return a true value. The code is run in package main , in its own lexical scope. However, if the script dies, $@ will not be set.</p> <p>The value of $Config{sitelib} is also determined in C code and not read from Config.pm , which is not loaded.</p> <p>The code is executed very early. For example, any changes made to @INC will show up in the output of <code>perl -V</code>. Of course, END blocks will be likewise executed very late.</p> <p>To determine at runtime if this capability has been compiled in your perl, you can check the value of $Config{usesitecustomize} .</p> </blockquote> <p>I've never done this, but it looks like if you put what you want in <code>$Config{sitelib}/sitecustomize.pl</code> you'll get what you are looking for.</p> <p>See:</p> <ul> <li><a href="http://perldoc.perl.org/perlrun.html" rel="noreferrer">http://perldoc.perl.org/perlrun.html</a></li> <li><a href="http://www.nntp.perl.org/group/perl.perl5.porters/2007/10/msg129926.html" rel="noreferrer">http://www.nntp.perl.org/group/perl.perl5.porters/2007/10/msg129926.html</a></li> </ul>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload