There are some moduls I use under linux.
Problem is that Cisco CLI may change prompt.
Checkout Net::SSH and Perl Expect. (Also there is a Modul called
Net::SSH::Expect,
which I had not tried yet.)
You may need to install Cygwin. This gives you a lot of linux utils.
HaveFun,
B.
monnappa appai
Thanks but I need STD output and STD error in the same file. How should I do
that.
Regards
Irfan.
-Original Message-
From: Nitin Kalra [mailto:[EMAIL PROTECTED]
Sent: Thursday, November 20, 2008 10:03 PM
To: Sayed, Irfan (Cognizant); beginners@perl.org
Subject: Re: help in redirecting
On Sun, Nov 23, 2008 at 20:07, John W. Krahn <[EMAIL PROTECTED]> wrote:
snip
>> checkfile($flag);
>> sub checkfile {
>> use File::Find;
>> use File::MMagic;
>> use FileHandle;
>
> use() happens at compile time so there is no point, but no harm, to put
> these inside a subroutine.
snip
This is n
On Sun, Nov 23, 2008 at 19:39, Rob Dixon <[EMAIL PROTECTED]> wrote:
snip
>> All Perl functionality works on UNIX. Some Perl functionality does
>> not work on Windows.
>
> No, not all Perl functionality works on all Unix platforms. You are as likely
> to
> find a compatibility issue moving from one
Thanks
"Mr. Shawn H. Corey" <[EMAIL PROTECTED]> wrote in
news:[EMAIL PROTECTED]:
> How would it parse "XMLSchema" ? You need to write down the rules
> before you try creating than regex for them. Try:
>
Ok - I am a typical customer - my stated requirement isn't quite my real
requirement :-)
Mr. Shawn H. Corey wrote:
On Sun, 2008-11-23 at 16:55 -0600, Harry Putnam wrote:
The program I'll post below is really only a test of a subroutine I
want to use in a larger program. Trying to get the subroutine ironed
out in this test script below so there is a little extra bumping
around to ge
Harry Putnam wrote:
The program I'll post below is really only a test of a subroutine I
want to use in a larger program. Trying to get the subroutine ironed
out in this test script below so there is a little extra bumping
around to get it executed as sub routine, but It fails with these
errors:
On Sun, Nov 23, 2008 at 16:17, monnappa appaiah <[EMAIL PROTECTED]> wrote:
> i forgot to mention that, i'l be running the script from the windows machine
> ..so pls let me know the module which can login to cisco devices
> using ssh, execute certain commands and give me the output.
>
> Than
Andrew schreef:
> I am tying to expand some camel case with spaces - but I want multiple
> captitals to remain as one word. So
> I want "PerlNotesOnXML" -> "Perl Notes On XML"
>
> My attempt is to use [A-Z]+ in a lookahead.
>
> my $text = "PerlNotesOnXML" ;
> $text =~ s/(?=[A-Z]+)/ /gx ;
> p
Stealth wrote:
> On Sunday 23 November 2008 12:58:06 pm David Ehresmann wrote:
>>
>> What is the difference between learning perl on windows vs. unix?
>
> Perl was originally developed on UNIX and was later made available
> for Windows. Perl on UNIX is in its natural environment.
perl on Unix is
On Sun, 2008-11-23 at 16:55 -0600, Harry Putnam wrote:
> The program I'll post below is really only a test of a subroutine I
> want to use in a larger program. Trying to get the subroutine ironed
> out in this test script below so there is a little extra bumping
> around to get it executed as sub
On Sun, Nov 23, 2008 at 17:55, Harry Putnam <[EMAIL PROTECTED]> wrote:
> The program I'll post below is really only a test of a subroutine I
> want to use in a larger program. Trying to get the subroutine ironed
> out in this test script below so there is a little extra bumping
> around to get it
The program I'll post below is really only a test of a subroutine I
want to use in a larger program. Trying to get the subroutine ironed
out in this test script below so there is a little extra bumping
around to get it executed as sub routine, but It fails with these
errors:
Variable "$rgx" wil
i forgot to mention that, i'l be running the script from the windows machine
..so pls let me know the module which can login to cisco devices
using ssh, execute certain commands and give me the output.
Thanks,
Monnappa
On Sun, Nov 23, 2008 at 11:51 PM, monnappa appaiah <[EMAIL PROTECTED]>
From: "David Ehresmann" <[EMAIL PROTECTED]>
ActivePerl-5.10.0.1004-MSWin32-x86-287188
Is this the best path or choice to install perl on windows?
It depends on what you want to do in perl, but generally ActivePerl is the
best choice for Windows.
What is the difference between learning perl
On Sunday 23 November 2008 12:58:06 pm David Ehresmann wrote:
> What is the difference between learning perl on windows vs. unix?
Perl was originally developed on UNIX and was later made available
for Windows. Perl on UNIX is in its natural environment. Perl on
Windows is in a modified environme
On Sun, Nov 23, 2008 at 08:29, loody <[EMAIL PROTECTED]> wrote:
> 2008/11/23 Chas. Owens <[EMAIL PROTECTED]>:
>>
>>
>> On Nov 23, 2008, at 2:52, loody <[EMAIL PROTECTED]> wrote:
>>
>>> Dear all:
>>> The prototype of read is
>>> read FILEHANDLE,SCALAR,LENGTH
>>> ex:
>>> read PATTERN, $line, 1920;
>>
On Sun, Nov 23, 2008 at 12:58, David Ehresmann <[EMAIL PROTECTED]> wrote:
snip
> Is this the best path or choice to install perl on windows?
snip
I would suggest Strawberry Perl*. It comes with its own C compiler
(so modules are easier to install). Of course, that is mostly because
I have been r
On Sun, Nov 23, 2008 at 7:31 PM, Rob Dixon <[EMAIL PROTECTED]> wrote:
> Rob Coops wrote:
> >>
> >> What is the difference between learning perl on windows vs. unix?
> >
> > The main difficulty you will run into is the fact that most examples and
> so
> > on you will find assume a windows machine
>
venu javarappa wrote:
>
> I can ask my cousin if she wants old tv
Yes, please would you? And can she collect from England?
Rob
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/
Rob Coops wrote:
>>
>> What is the difference between learning perl on windows vs. unix?
>
> The main difficulty you will run into is the fact that most examples and so
> on you will find assume a windows machine
No, most platform-dependent examples will assume a Unix machine. But there are a
lot
David Ehresmann wrote:
>
> If I want to install perl for the computer described below:
>
> Windows Vista Home Premium
> Service Pack 1
> Intel Pentium Dual CPU E2200 2.2GHz 2GB memory
> 32-bit
>
> I would go to ActivePerl and download this:
>
> ActivePerl-5.10.0.1004-MSWin32-x86-287188
>
> Is
I can ask my cousin if she wants old tv
-Original Message-
From: "Rob Coops" <[EMAIL PROTECTED]>
Date: Sun, 23 Nov 2008 19:22:04
To: David Ehresmann<[EMAIL PROTECTED]>
Cc:
Subject: Re: perl version for windows
On Sun, Nov 23, 2008 at 6:58 PM, David Ehresmann <[EMAIL PROTECTED]>wrote:
On Sun, Nov 23, 2008 at 6:58 PM, David Ehresmann <[EMAIL PROTECTED]>wrote:
> If I want to install perl for the computer described below:
>
>
> Windows Vista Home Premium
>
> Service Pack 1
>
> Intel Pentium Dual CPU E2200 2.2GHz 2GB memory
>
> 32-bit
>
>
>
> I would go to ActivePerl and download
Hi all,
I'm looking for a module which can login to cisco devices using
ssh, execute certain commands and give me the output.can
somebody suggest me
the module which is best suitable for loggin into cisco devices via ssh.
Thanks,
Monnappa
Hi all
I'm getting error while installing Net::SSH2 module on Kubuntu
linux 8.10, I had installed the same module on in a different machine which
was also running Kubuntu linux 8.10can somebody please help me
with this, find the error below.
If I want to install perl for the computer described below:
Windows Vista Home Premium
Service Pack 1
Intel Pentium Dual CPU E2200 2.2GHz 2GB memory
32-bit
I would go to ActivePerl and download this:
ActivePerl-5.10.0.1004-MSWin32-x86-287188
Is this the best path or choice to insta
Andrew wrote:
> I am tying to expand some camel case with spaces - but I want multiple
> captitals to remain as one word. So
> I want "PerlNotesOnXML" -> "Perl Notes On XML"
>
> My attempt is to use [A-Z]+ in a lookahead.
>
> my $text = "PerlNotesOnXML" ;
> $text =~ s/(?=[A-Z]+)/ /gx ;
>
Mr. Shawn H. Corey wrote:
On Sun, 2008-11-23 at 05:47 -0800, John W. Krahn wrote:
Mr. Shawn H. Corey wrote:
On Sun, 2008-11-23 at 05:34 -0800, John W. Krahn wrote:
You shouldn't "do something with $line" if $bytes_read is undefined:
while ( my $bytes_read = read PATTERN, $line, 1920 ) {
On Sun, 2008-11-23 at 05:47 -0800, John W. Krahn wrote:
> Mr. Shawn H. Corey wrote:
> > On Sun, 2008-11-23 at 05:34 -0800, John W. Krahn wrote:
> >> You shouldn't "do something with $line" if $bytes_read is undefined:
> >>
> >> while ( my $bytes_read = read PATTERN, $line, 1920 ) {
> >> unless
Mr. Shawn H. Corey wrote:
On Sun, 2008-11-23 at 05:34 -0800, John W. Krahn wrote:
You shouldn't "do something with $line" if $bytes_read is undefined:
while ( my $bytes_read = read PATTERN, $line, 1920 ) {
unless ( defined $bytes_read ) {
die "error reading $filename: $!";
loody wrote:
2008/11/23 Chas. Owens <[EMAIL PROTECTED]>:
On Nov 23, 2008, at 2:52, loody <[EMAIL PROTECTED]> wrote:
The prototype of read is
read FILEHANDLE,SCALAR,LENGTH
ex:
read PATTERN, $line, 1920;
that means the $line will content 1920 bytes.
if I want to modify the byte offset 720 of $
On Sun, 2008-11-23 at 05:34 -0800, John W. Krahn wrote:
> You shouldn't "do something with $line" if $bytes_read is undefined:
>
> while ( my $bytes_read = read PATTERN, $line, 1920 ) {
> unless ( defined $bytes_read ) {
> die "error reading $filename: $!";
> }
> # do s
Mr. Shawn H. Corey wrote:
On Sun, 2008-11-23 at 15:52 +0800, loody wrote:
The prototype of read is
read FILEHANDLE,SCALAR,LENGTH
ex:
read PATTERN, $line, 1920;
that means the $line will content 1920 bytes.
It means it will attempt to read 1920 bytes. The actual number of bytes
read is retur
2008/11/23 Chas. Owens <[EMAIL PROTECTED]>:
>
>
> On Nov 23, 2008, at 2:52, loody <[EMAIL PROTECTED]> wrote:
>
>> Dear all:
>> The prototype of read is
>> read FILEHANDLE,SCALAR,LENGTH
>> ex:
>> read PATTERN, $line, 1920;
>>
>> that means the $line will content 1920 bytes.
>> if I want to modify th
Andrew wrote:
I am tying to expand some camel case with spaces - but I want multiple
captitals to remain as one word. So
I want "PerlNotesOnXML" -> "Perl Notes On XML"
My attempt is to use [A-Z]+ in a lookahead.
my $text = "PerlNotesOnXML" ;
$text =~ s/(?=[A-Z]+)/ /gx ;
print $text ;
I
On Sun, 2008-11-23 at 11:52 +, Andrew wrote:
> I am tying to expand some camel case with spaces - but I want multiple
> captitals to remain as one word. So
> I want "PerlNotesOnXML" -> "Perl Notes On XML"
>
> My attempt is to use [A-Z]+ in a lookahead.
>
> my $text = "PerlNotesOnXML" ;
>
On Sun, 2008-11-23 at 15:52 +0800, loody wrote:
> Dear all:
> The prototype of read is
> read FILEHANDLE,SCALAR,LENGTH
> ex:
> read PATTERN, $line, 1920;
>
> that means the $line will content 1920 bytes.
It means it will attempt to read 1920 bytes. The actual number of bytes
read is returned. Y
I am tying to expand some camel case with spaces - but I want multiple
captitals to remain as one word. So
I want "PerlNotesOnXML" -> "Perl Notes On XML"
My attempt is to use [A-Z]+ in a lookahead.
my $text = "PerlNotesOnXML" ;
$text =~ s/(?=[A-Z]+)/ /gx ;
print $text ;
I think I can se
loody wrote:
Dear all:
Hello,
I try to use perl to compare 2 binary files, one is display content
dump from Dram and another is display content calculated by my c-model
code.
I use open and binmode to open these 2 files, and use programs as
below to do the comparison:
$num_patter
On Nov 23, 2008, at 2:52, loody <[EMAIL PROTECTED]> wrote:
Dear all:
The prototype of read is
read FILEHANDLE,SCALAR,LENGTH
ex:
read PATTERN, $line, 1920;
that means the $line will content 1920 bytes.
if I want to modify the byte offset 720 of $line, it seems impossible,
But happily it isn'
41 matches
Mail list logo