Re: Environment variable evaluation in a conditional

2007-09-23 Thread kens
On Sep 21, 3:48 pm, [EMAIL PROTECTED] wrote: > On Sep 20, 9:29 am, [EMAIL PROTECTED] wrote: > > > > > On Sep 20, 2:54 am, [EMAIL PROTECTED] (Rob Dixon) wrote: > > > > [EMAIL PROTECTED] wrote: > > > > > I am currently trying to write a Perl program in a Solaris 9 > > > > environment > > > > I am try

Re: Environment variable evaluation in a conditional

2007-09-22 Thread Tom Phoenix
On 9/21/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > $dir_to_check = `echo $dir_to_check`; > > if (-e $dir_to_check) now finds the appropriate directory. Does it really? When $dir_to_check ends with a newline? Surely you jest. But just for fun my $dir_to_check = 'fred; rm /your/favo

Re: Environment variable evaluation in a conditional

2007-09-22 Thread smdspamcatcher
On Sep 20, 9:29 am, [EMAIL PROTECTED] wrote: > On Sep 20, 2:54 am, [EMAIL PROTECTED] (Rob Dixon) wrote: > > > > > > > [EMAIL PROTECTED] wrote: > > > > I am currently trying to write a Perl program in a Solaris 9 > > > environment > > > I am trying to process a list of variables with UNIX environmen

Re: Environment variable evaluation in a conditional

2007-09-21 Thread Rob Dixon
[EMAIL PROTECTED] wrote: On Sep 20, 2:54 am, [EMAIL PROTECTED] (Rob Dixon) wrote: [EMAIL PROTECTED] wrote: I am currently trying to write a Perl program in a Solaris 9 environment I am trying to process a list of variables with UNIX environment variables embedded in them of the form $dir_to_

Re: Environment variable evaluation in a conditional

2007-09-21 Thread smdspamcatcher
On Sep 20, 2:54 am, [EMAIL PROTECTED] (Rob Dixon) wrote: > [EMAIL PROTECTED] wrote: > > > I am currently trying to write a Perl program in a Solaris 9 > > environment > > I am trying to process a list of variables with UNIX environment > > variables embedded in them of the form > > $dir_to_check =

Re: Environment variable evaluation in a conditional

2007-09-20 Thread useperl-jeff
--- Rob Dixon <[EMAIL PROTECTED]> wrote: > > > > It's `-d dir` for directory exist test. > > `-e` is for file exist test. > > Not really. It's > > -e for item exists > -d for item exists and is a directory > -f for item exists and is a plain file > Sorry,my mistake.You're right.

Re: Environment variable evaluation in a conditional

2007-09-20 Thread Rob Dixon
[EMAIL PROTECTED] wrote: --- [EMAIL PROTECTED] wrote: I am currently trying to write a Perl program in a Solaris 9 environment I am trying to process a list of variables with UNIX environment variables embedded in them of the form $dir_to_check = "$ENV_VAR1/some_dir/$ENV_VAR2/another_dir"; and

Re: Environment variable evaluation in a conditional

2007-09-20 Thread Rob Dixon
[EMAIL PROTECTED] wrote: I am currently trying to write a Perl program in a Solaris 9 environment I am trying to process a list of variables with UNIX environment variables embedded in them of the form $dir_to_check = "$ENV_VAR1/some_dir/$ENV_VAR2/another_dir"; and I am trying to find if another

Re: Environment variable evaluation in a conditional

2007-09-20 Thread useperl-jeff
--- [EMAIL PROTECTED] wrote: > I am currently trying to write a Perl program in a Solaris 9 > environment > I am trying to process a list of variables with UNIX environment > variables embedded in them of the form > $dir_to_check = "$ENV_VAR1/some_dir/$ENV_VAR2/another_dir"; > and I am trying to