Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid
 
PerlMonks  

Re^6: 'do' command is dead? Surely not?

by ACI (Acolyte)
on May 19, 2017 at 15:08 UTC ( #1190638=note: print w/replies, xml ) Need Help??


in reply to Re^5: 'do' command is dead? Surely not?
in thread 'do' command is dead? Surely not?

AHHH!!! my $file='/home/andy/Desktop/test-response.pl'; works!!!! I'm assuming something happened in a recent update. Edit - './test-response.pl' works too. EDIT2 - use lib '.'; my $file='test-response.pl'; also works

(but, given that my Perl portfolio contains thousands of these, is there a way of telling Perl never to require the absolute path, other than use lib '.'? I think I now understand the importance of '.' in @INC, but soooooo many scripts to edit!)

Replies are listed 'Best First'.
Re^7: 'do' command is dead? Surely not?
by Corion (Pope) on May 19, 2017 at 17:13 UTC

    See perlrun on how to modify @INC globally via $ENV{PERL5LIB}.

    Personally, I would modify the scripts on an as-needed basis.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1190638]
help
Chatterbox?
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (9)
As of 2017-12-13 20:55 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    What programming language do you hate the most?




















    Results (378 votes). Check out past polls.

    Notices?