in reply to Re: How do I find what dir the perl script is running from?
in thread How do I find what directory the perl script is running from?

Even better (for Unix), you can try one of the following...

$var = `/usr/bin/pwd`; # put the current dir in to $var

print `/usr/bin/pwd`; # print the cwd to STDOUT

  • Comment on Re: Answer: How do I find what dir the perl script is running from?

Replies are listed 'Best First'.
Re: Re: Answer: How do I find what dir the perl script is running from?
by Anonymous Monk on Sep 16, 2003 at 23:38 UTC
    this way you'll get dir the script is running _on_, and not the path script is running _from_