e
Internet, point your browser at http://www.perl.com/, the Perl Home
Page.
P.S. Although our initials are the same, I am not related to Jair :)
-Original Message-
From: John W. Krahn [mailto:[EMAIL PROTECTED]
Sent: Monday, June 16, 2003 4:12 PM
To: [EMAIL PROTECTED]
Subject: R
ActivePerl 5.8
- Original Message -
From: "John W. Krahn" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Monday, June 16, 2003 3:41 PM
Subject: Re: Is empty directory?
> Jair Santos wrote:
> >
> > From: "John W. Krahn" <[EMAIL P
Is it a DOS or UNIX box ? Mine is DOS and it works.
- Original Message -
From: "John W. Krahn" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Monday, June 16, 2003 2:57 PM
Subject: Re: Is empty directory?
> Jair Santos wrote:
> >
> > > Tha
> That is because "= =" is a syntax error, it should be "==" with no
> whitespace between the two equals signs. Since the expression is in a
> boolean context the "== 0" part can be omitted and it will do the same
> thing.
Thats ok, but it was NOT a sintax error. The script was running properly
w
.
Could you explain what exactly this part of the line does. grep !
/^\.{1,2}/
Is it a search over the readdir result set ?
Jair
- Original Message -
From: "Charles K. Clarkson" <[EMAIL PROTECTED]>
To: "'Jair Santos'" <[EMAIL PROTECTED]>
Sent:
Thanks John,
it is clear enough.
regards
Jair
- Original Message -
From: "John W. Krahn" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Monday, June 16, 2003 10:59 AM
Subject: Re: Is empty directory?
> Jair Santos wrote:
> >
> > Thank to
IsEmptyDir {
my ( $directory) = @_ ;
return undef unless -d $_[0];
opendir my $dh, $_[0] or die $!;
my $count = () = readdir $dh;
return $count - 2;
}
- Original Message -
From: "Mark G" <[EMAIL PROTECTED]>
To: "Jair Santos" <[EMAIL PROTECTED]&
Hi all,
say that
$directory = "C:\\directory\\*.*"
and I am trying to remove the *.* from the end using
$directory = trim($directory);
where
trim is
sub trim {
my( $result) = @_;
$result =~ s/^\s+(.*?)\s+$/$1/;
$result =~ s/\s//g;
return $result;
}
Can anybody point me out why
Please, send the code to the list. I would like to know because have a
similar problem.
thanks
Jair
- Original Message -
From: "Tony Esposito" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Monday, June 09, 2003 10:14 AM
Subject: RE: Mail::Mailer
> You all can ignore this thread..
You have to include the go_next; in your while loop.
Jair
- Original Message -
From: "Pedro Antonio Reche" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Friday, June 06, 2003 3:40 PM
Subject: processing text in perl script
> Hi All,
>
> I would like to read and proces
Thanks all,
it is simple and works.
Jair
- Original Message -
From: "Mark G" <[EMAIL PROTECTED]>
To: "Jair Santos" <[EMAIL PROTECTED]>
Cc: "perl" <[EMAIL PROTECTED]>
Sent: Thursday, June 05, 2003 9:09 PM
Subject: Re: Is empty directory
Hi all,
does anybody knows how to check if a diretory is empty?
TIA
Jair
12 matches
Mail list logo