foreach my $File (@Files) {
print $File "\n";
This print statement is treating $File as a file handle. It is similar to:
print STDERR "\n";
I saw the typo a few minutes after I sent the email (it always happens
that way!). At least I'm not loosing my mind yet :)
--
Chris
-
Hi,
I have the following code:
#!/usr/bin/perl
use diagnostics;
use strict;
use warnings;
my @Files = ;
foreach my $File (@Files) {
print $File "\n";
}
I have the following files in /flows/
r...@stats1:/flows# ls -l
total 245M
-rwxrwxr-x 1 root root 146 Oct 13 15:31 ParseNetFlow*
-rw-r--r--
if (($_ =~ m/match string/i) && ($_ !~ m/does not match string/i)) {
Works flawlessly, thanks allot...
--
Chris
Quoting Shashidhara Bapat <[EMAIL PROTECTED]>:
> Hi,
>
> yes you can do that. For "not match", you got to use "!~".
>
> - shashi
>
> On 5/31/06, [EMAIL PROTECTED] <[EMAIL PROTECT
Hi,
if ($_ =~ m/match string/i) {
if ($_ =~ m/does not match string/i) {
} else {
print $_;
Regex is not my strong point, so I'm going to ask... Is there any way to write
that better? Preferably only using one if statement?
if (($_ =~ m/match string/i) && ($_ =~ m/does not matc
Quoting Dan <[EMAIL PROTECTED]>:
>
> "Japerlh" <[EMAIL PROTECTED]> wrote in message
> news:[EMAIL PROTECTED]
> Help: Is there any way to get the name of the Window Server that the
> Perl script is currently running on?
>
> Thanks.
Uhm, there is always the hostname.exe command as well if you wa