Re: DFA::Simple

2005-04-25 Thread Edward Wijaya
--- Alex Lisbaron <[EMAIL PROTECTED]> wrote: > How can I install this package on WIN2K? Use PPM, like: dos-prompt> ppm then ppm> install DFA-Simple --- Regards, Edward WIJAYA SINGAPORE -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

Re: one-liner multi-line regex problem

2005-04-25 Thread Kevin Horton
On 25-Apr-05, at 10:06 AM, Jay Savage wrote: On 4/25/05, Kevin Horton <[EMAIL PROTECTED]> wrote: I'm trying to write a perl one-liner that will edit an iCalendar format file to remove To Do items. The file contains several thousand lines, and I need to remove several multi-line blocks. The blocks

Re: one-liner multi-line regex problem

2005-04-25 Thread Kevin Horton
On 25-Apr-05, at 10:06 AM, Jay Savage wrote: On 4/25/05, Kevin Horton <[EMAIL PROTECTED]> wrote: I'm trying to write a perl one-liner that will edit an iCalendar format file to remove To Do items. The file contains several thousand lines, and I need to remove several multi-line blocks. The blocks

DFA::Simple

2005-04-25 Thread Alex Lisbaron
Hi All, I need to create fsa (final state machine). I want to do it using DFA::Simple. How can I install this package on WIN2K? Thank you in advance A. -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

Re: Very basic question about running perl cgi on tomcat

2005-04-25 Thread Robert Kerry
Chris, Thanks. I'm not switching to Apache http server. Unfortunately the same thing happened again. I put the first.pl in the /cgi-bin/ directory and try to access it via http://localhost/cgi-bin/first.pl, it tells me that file not found. I don't know what I should do for httpd.conf file. Thanks

Re: Reading multi line input from user

2005-04-25 Thread Jay Savage
On 4/25/05, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > I wish to read input from a user that has multiple lines with carriage > returns from but not actually stop reading until a single # on a > line by itself. Is there a module / package / function that will aid in > this? I would like to do

Re: Perl One-liner de-compile?

2005-04-25 Thread John W. Krahn
Larsen, Errin M HMMA/IT wrote: > > Ok ... So I tried this: > > # perl -MO=Deparse -nae 'print $f[4]' /some/directory/somefile ^ > LINE: while (defined($_ = )) { > our(@F) = split(" ", $_, 0); > print $f[4]; ^ > } > -e synt

RE: Perl One-liner de-compile?

2005-04-25 Thread Larsen, Errin M HMMA/IT
> -Original Message- > From: Jeff 'japhy' Pinyan [mailto:[EMAIL PROTECTED] > Sent: Monday, April 25, 2005 2:42 PM > To: Larsen, Errin M HMMA/IT > Cc: beginners@perl.org > Subject: RE: Perl One-liner de-compile? > <> > > You're using a lowercase @f here. > <> > > Perl will magically

Re: 'Bad index while coercing array into hash' error

2005-04-25 Thread jason_normandin
Hello List. Found the problem: foreach my $record (@{dataFileHash{$datafile}}) { Should have been: foreach my $record (@{$dataFileHash{$datafile}}) { Sorry ! I stared at this for like an hour and didn't notice the missing $ Can anyone tell me what the Argument "NH_DATA01" isn't numeric in

RE: Perl One-liner de-compile?

2005-04-25 Thread Jeff 'japhy' Pinyan
On Apr 25, Larsen, Errin M HMMA/IT said: $ perl -MO=Deparse -ane 'print pop(@F), "\n";' Note the @F, it's capital-F. # perl -MO=Deparse -nae 'print $f[4]' /some/directory/somefile You're using a lowercase @f here. LINE: while (defined($_ = )) { our(@F) = split(" ", $_, 0); print $f[4];

RE: Perl One-liner de-compile?

2005-04-25 Thread Charles K. Clarkson
Larsen, Errin M HMMA/IT wrote: : Or is the @f array a secret array I'm not cleared to know about? We could tell 'ya, but then we'd have to kill 'ya. -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

'Bad index while coercing array into hash' error

2005-04-25 Thread jason_normandin
Greetings I am getting the following error when running a script using an anonymous array of hashes: Bad index while coercing array into hash at ./nhsDiffSchema.pl line 240 Here is the code snipt that both assigns values to the array of hashes and the code which displays the values back (where

RE: Perl One-liner de-compile?

2005-04-25 Thread Larsen, Errin M HMMA/IT
> -Original Message- > From: Paul Johnson [mailto:[EMAIL PROTECTED] > Sent: Monday, April 25, 2005 1:53 PM > To: Larsen, Errin M HMMA/IT > Cc: beginners@perl.org > Subject: Re: Perl One-liner de-compile? > > > On Mon, Apr 25, 2005 at 01:45:15PM -0500, Larsen, Errin M > HMMA/IT wrote: >

Re: Perl One-liner de-compile?

2005-04-25 Thread Paul Johnson
On Mon, Apr 25, 2005 at 01:45:15PM -0500, Larsen, Errin M HMMA/IT wrote: > Hi everyone, > > Here is an example from the perlrun perldoc page: > > perl -ane 'print pop(@F), "\n";' > > is equivalent to > > while(<>) { > @F = split(' '); > print pop(@F), "\n"; > }

Perl One-liner de-compile?

2005-04-25 Thread Larsen, Errin M HMMA/IT
Hi everyone, Here is an example from the perlrun perldoc page: perl -ane 'print pop(@F), "\n";' is equivalent to while(<>) { @F = split(' '); print pop(@F), "\n"; } My question is, can I get Perl to evaluate a command line (like above) and print out the

Re: Perl one-liner to print columns

2005-04-25 Thread Jay Savage
On 4/25/05, Jay Savage <[EMAIL PROTECTED]> wrote: > On 4/25/05, Larsen, Errin M HMMA/IT <[EMAIL PROTECTED]> wrote: > > Hi Perlers, > > > > I typically will type the following to collect a specific column of > > data from some command's output: > > > > # some_command | awk '{print $4}' > > > >

Very basic question about running perl cgi on tomcat

2005-04-25 Thread Robert Kerry
I changed the web.xml file and the .jar suffix as required, and create a new directory WEB-INF/cgi/ under webapps/ directory, I put my first.pl into that directory, and try to visit it using http://localhost:8080/cgi/first.pl but it doesn't work. I've also tried /cgi-bin/first.pl and something else

Re: Perl one-liner to print columns

2005-04-25 Thread Jay Savage
On 4/25/05, Larsen, Errin M HMMA/IT <[EMAIL PROTECTED]> wrote: > Hi Perlers, > > I typically will type the following to collect a specific column of > data from some command's output: > > # some_command | awk '{print $4}' > > I wanted to start using perl one-liners more often, so I thought

Perl one-liner to print columns

2005-04-25 Thread Larsen, Errin M HMMA/IT
Hi Perlers, I typically will type the following to collect a specific column of data from some command's output: # some_command | awk '{print $4}' I wanted to start using perl one-liners more often, so I thought I'd try the column thing first. This is what I came up with: # some_comma

Re: How to add my own start method to existing HTML::Parser class to Scrape Screens?

2005-04-25 Thread Wiggins d'Anconia
Siegfried Heintze wrote: > I'm trying to screen scape some information off the web. > > I anticipate that I'll want to have it multi-threaded. > > As per Lincoln Stein's book, I'm using HTML::Parser and passing a function > pointer (you can tell I'm a C programmer) to $parser->handler(start=> >

Re: one-liner multi-line regex problem

2005-04-25 Thread Dave Gray
> I'm trying to write a perl one-liner that will edit an iCalendar > format file to remove To Do items. The file contains several > thousand lines, and I need to remove several multi-line blocks. The > blocks to remove start with a line "BEGIN:VTODO" (without the quotes) > and end with a line "EN

Re: getting file name/line num info

2005-04-25 Thread Jay Savage
On 4/25/05, Manish Sapariya <[EMAIL PROTECTED]> wrote: > Hello, > Can somebody explain me the magic here > sub vprint (@) { # subroutine declaration with prototype return unless $Utils::verbose; # exit sub unless $Utils::verbose flag is set my ($file, $line)

Re: Regular expression help

2005-04-25 Thread Jay Savage
On 4/25/05, John W. Krahn <[EMAIL PROTECTED]> wrote: > Owen wrote: > > I found a message from Randal Schwartz, Message-ID: > > <[EMAIL PROTECTED]>#1/1 > > which gave a regular expression for a valid Unix name, > > > > /^(?=.*?\D)[a-z\d]+$/ > > > > That works but why does it work? > > > >

getting file name/line num info

2005-04-25 Thread Manish Sapariya
Hello, Can somebody explain me the magic here = sub vprint (@) { return unless $Utils::verbose; my ($file, $line) = (caller)[1,2]; my $subr = (caller 1)[3] || 'main'; $file =~ s!.*/!!; print STDERR "$subr($file:$line): ", @_; } What wo

Re: Configuration File generator

2005-04-25 Thread Offer Kaye
On 4/24/05, Tommy Nordgren wrote: > I wan't links to any useful tools for generating configure scripts in > perl. > That is, tools to automatically generate the configure script for > open-source > C/C++ projects. > Perl itself uses a "Configure" script generated using the "metaconfig" tool, whic

Re: one-liner multi-line regex problem

2005-04-25 Thread Jay Savage
On 4/25/05, Kevin Horton <[EMAIL PROTECTED]> wrote: > I'm trying to write a perl one-liner that will edit an iCalendar > format file to remove To Do items. The file contains several > thousand lines, and I need to remove several multi-line blocks. The > blocks to remove start with a line "BEGIN:V

Re: Getopt::Mixed

2005-04-25 Thread Offer Kaye
On 4/23/05, Carlos Mantero wrote: > Hi everybody! I'm very newbie programmer of Perl and I can't make a > little program with a small number of arguments with this Perl module, > Getopt::Mixed. I like that somebody will can make a simple program > exemple with some argument. Thanks for all. > Get

RE: Reading multi line input from user

2005-04-25 Thread Bob Showalter
[EMAIL PROTECTED] wrote: > I wish to read input from a user that has multiple lines with carriage > returns from but not actually stop reading until a single # > on a line by itself. You can use perl's $/ variable to define an record separator. The default is "\n", but you can change it. Try th

Re: General Enquiry regarding the Perl

2005-04-25 Thread Rajat Dudeja
Hello, Thanks a lot Teddy ,Chris ,Brian and Ashoka for letting me know such a wide scope of perl. Just one more enquiry...hope you guys won't mind. Right now i am reading the book "Learning Perl". After going through this book I am intending to read "Perl Cookbook" ,would it be right ? Or, shal

Reading multi line input from user

2005-04-25 Thread christopher . l . hood
I wish to read input from a user that has multiple lines with carriage returns from but not actually stop reading until a single # on a line by itself. Is there a module / package / function that will aid in this? I would like to do something like below: Until( = "#") { $incoming_

Re: one-liner multi-line regex problem

2005-04-25 Thread John Doe
Hi Kevin just hints, no solution :-) Am Montag, 25. April 2005 12.59 schrieb Kevin Horton: > I'm trying to write a perl one-liner that will edit an iCalendar > format file to remove To Do items. The file contains several > thousand lines, and I need to remove several multi-line blocks. The > bl

one-liner multi-line regex problem

2005-04-25 Thread Kevin Horton
I'm trying to write a perl one-liner that will edit an iCalendar format file to remove To Do items. The file contains several thousand lines, and I need to remove several multi-line blocks. The blocks to remove start with a line "BEGIN:VTODO" (without the quotes) and end with a line "END:VTOD

Re: basic class problem

2005-04-25 Thread John Doe
Hi Graeme [rearranged from bottom:] > All I want to do is print off the value of the hash refs at the moment > before I start building on it. Due to my bad english I'm not quite shure what you mean by that. You want to print the values to be sure they are right, before using them? > I know I'm

Re: Use Perl to extract keywords

2005-04-25 Thread John Doe
Hi Robert Am Montag, 25. April 2005 01.45 schrieb Robert Kerry: > I want to use Perl to extract keywords from plaintext, don't know > whether there are some exsiting package / algorithm for doing that? > Thank you. In the case you know the keywords (I suppose so, otherwise you would search word

Re: Lines Interchange

2005-04-25 Thread N. Ganesh Babu
Dear Charles, The rules are as follows: 1. The first tag should be 2 . The second tag should be 3. The third tag should 4. The fourth tag should be 5. The fifth tag should be 6. Next, the set of 4 tags (, , and ) may come multiple times. may come multipe times with in the set. Example: