Why not use '.'
print "WHOOT" if -e "./ThisDir" and -d _;
the -d _ uses the cached results from the last stat, in this case the -e
"./ThisDir".
Peter C.
-Original Message-
From: Chris [mailto:[EMAIL PROTECTED]]
Sent: Monday, January 14, 2002 8:46 PM
To: [EMAIL PROTECTED]
Subject: 2 sim
On Mon, Jan 14, 2002 at 10:45:35PM -0600, Chris wrote:
> On the path issue:
>
> What I need to do is to verify if a specific directory exists in the
> current directory:
>
> if exists($PWD/ThisDir) then
>print "WH00T"
> End If
---end quoted text---
$_='/home/frank/';
print "foo" if -e "$_
> -Original Message-
> From: Chris Anderson [mailto:[EMAIL PROTECTED]]
> Sent: Monday, January 14, 2002 10:58 PM
> To: [EMAIL PROTECTED]
> Subject: 2 simple questions...
>
>
> I need to be able to do a wget (But not with a system() command if
> possible)
Use the LWP family of modules.
A portable solution would be to use the Cwd module. Try this
use Cwd;
print cwd();
On a windows machine with cygwin this is different from $ENV{PWD}. cwd()
gives me c:\cygwin\home\peterc while $ENV{PWD} is /home/peterc.
As for the wget thing, you should look into the LWP modules. I think
LW
On Monday 14 January 2002 08:58 pm, Chris Anderson wrote:
> I need to be able to do a wget (But not with a system() command if
> possible)
> I need to get the current directory. In Linux I type pwd and it shows it
> to me, or
> I can use the $PWD variable. But if I :
> print "The current p