Electron One wrote, on Monday, March 10, 2003 13:12
: while(<>){
: chomp;
: if(/\s*\$[a-z]\w+\s*/i){
: #if(/\b\$[a-z]\w+\b/i){
: print "Matched: $` -- $& -- $' :\n";
: }
: else{
:print "No match:$_\n";
: }
: }
:
: testfile.txt###
At 12:06 PM 3/10/2003 -0800, Ted Zeng wrote:
if(/\$\b[a-z]\w+\b/i)
should work.
If i do this, it will still include this line,
I sure hope this doesnt pass alf$f12w32 cuz it shouldnt
And I want it to be a word that starts off with the "$" symbol. :-(
"\b" only includes those chars in "\w" w
if(/\$\b[a-z]\w+\b/i)
should work. "\b" only includes those chars in "\w" which doesn't include
"$". So "$" is not include in the word, only "hello" is included.
ted zeng
"Stovall, Adrian M." wrote:
> > -Original Message-
> > From: Electron One [mailto:[EMAIL PROTECTED]
> > Sent: Monda
> -Original Message-
> From: Electron One [mailto:[EMAIL PROTECTED]
> Sent: Monday, March 10, 2003 12:12 PM
> To: [EMAIL PROTECTED]
> Cc: Electron One
> Subject: Another Regular expression problem
>
>
> Hello Everyone,
>
>I have a perl file that has this,
>
> ##
A few issues on the regex:
1. Dot "." has special meaning, so escape it.
Without the escape, it means "Match any
single character with the exception of a
new line character."
2. The filename may contain more than one dot,
so tell the regex if the file contains one
or more dots, we'
Hello Everyone,
I have a perl file that has this,
PerlFile.pl###
#!/usr/bin/perl
while(<>){
chomp;
if(/\s*\$[a-z]\w+\s*/i){
#if(/\b\$[a-z]\w+\b/i){
print "Matched: $` -- $& -- $' :\n";
}
el
unless ($_ =~ .) {}
-~.-~.-~.-~.-~.-~.-~.-~.-~.-~
-~
-~ Cliff Frensley
-~ [EMAIL PROTECTED]
-~ Seattle, WA
-~
-~
-.
On Mon, 10 Mar 2003, Andrew Mansfield wrote:
> I want to match files that have no period in their filename.
>
> So far I have:
>
> use strict;
> use warnings;
>
> my $sta
Andrew Mansfield wrote:
I want to match files that have no period in their filename.
if( $_ =~ /[^.]/) {
if( $_ !~ /\./) {
or
unless( /\./ ) {
--
Simon Oliver
___
Perl-Win32-Users mailing list
[EMAIL PROTECTED]
To unsubscribe: http://
At 11:41 AM 3/10/2003 -0600, Andrew Mansfield wrote:
I want to match files that have no period in their filename.
use strict;
use warnings;
my $start_dir = $ARGV[0] || ".";
use File::Find;
print "Temp file list:\n";
find sub {
return unless -f;
my $file=$File::Find::name;
print "$
> I want to match files that have no period in their filename.
>
> So far I have:
>
> use strict;
> use warnings;
>
> my $start_dir = $ARGV[0] || ".";
> use File::Find;
> print "Temp file list:\n";
> find sub {
> return unless -f;
> my $file=$File::Find::name;
> if( $_ =~ /[^.]
I want to match files that have no period in their filename.
So far I have:
use strict;
use warnings;
my $start_dir = $ARGV[0] || ".";
use File::Find;
print "Temp file list:\n";
find sub {
return unless -f;
my $file=$File::Find::name;
if( $_ =~ /[^.]/) {
print "$fil
Ricci, Mark wrote:
Does anybody have links to examples of IO::Socket?
All I have been able to find is the manpage.
The perlipc man page has some good examples on creating client/server
applications. Also read IO::Select if your server needs to talk to more
than one client at a time.
In the lis
Does anybody have links to examples of IO::Socket?
All I have been able to find is the manpage.
Thanks in advance,
Mark
-Original Message-
From: Ricci, Mark
Sent: Monday, March 10, 2003 10:40 AM
To: 'Simon Oliver'; Ricci, Mark
Cc: '[EMAIL PROTECTED]'
Subject: RE: Module to open port and
Thanks, Simon.
In the lists opinion, how robust is IO::Socket? Is it limited in what it
can do? I'm looking to setup a client/server connection and pass large
amount of data thru in a short amount of time.
Thanks in advance,
Mark
-Original Message-
From: Simon Oliver [mailto:[EMAIL PR
Ricci, Mark wrote:
>Is there a perl module that will open a specified port on a server
> and receive data on it?
Socket, IO::Socket or Net::Telnet
--
Simon Oliver
___
Perl-Win32-Users mailing list
[EMAIL PROTECTED]
To unsubscribe: http://listserv.A
Hello All,
Is there a perl module that will open a specified port on a server
and receive data on it?
Thanks in advance,
Mark
This e-mail message is for the sole use of the intended recipient(s) and may
contain confidential and/or privileged information. Any review, use,
On 07/03/2003 20:06:49 "Joel Brockman" wrote:
>
>Csaba,
>Thank you for your effort. ActiveState provided me with an html document
>containing a link to OLE Browser. The link brings up a blank page.
That should not happen. Is that C:\Perl\html\OLE-Browser\Browser.html ?
If there is an error, t
After reading another mail, I have just discovered the OLE browser.
Is there any kind of help or tutorial on this, as some things I've looked up
are rather cryptic, and don't actually help me much?
Or should I remove myself from the Gene pool, as I'm obviously far too
stupid to procreate? ;-)
Th
\b is the answer:
--
while () {
chomp;
if (/\bwilma\b/) {
print "wilma was mentioned\n";
}
}
__DATA__
wilma
wimagren was here
twilma was type wilma
wilma
wilma
wilma
twowilmase
Not if the fourth to sixth lines don't have a space before the end of line.
Try if(/wilma\s*/). Actually, you'll need to use if(/wilma/g) to catch them
all.
Phil.
|-+--->
| | Electron One|
| |
-8<-
use Net::Telnet;
$telnet = new Net::Telnet (Timeout => 20, Prompt => '/[%#>\]] *$/');
-8<-
In the previous code I am accessing a network switch remotely, implement
a command on it "ipmac" for several time to get all output and send it
to a txt f
21 matches
Mail list logo