Re: Convert letter to phone keypad equivalent

2004-01-02 Thread Tom Kinzer
You could do it with a mathematical operation based on the ASCII value...course that's not a regex. -Tom Kinzer -Original Message- From: Kevin Old <[EMAIL PROTECTED]> Sent: Jan 2, 2004 8:26 AM To: [EMAIL PROTECTED] Subject: Convert letter to phone keypad equivalent Hel

RE: generating GIFs

2003-12-29 Thread Tom Kinzer
sounds like a new sourceforge project is hatched...? -Original Message- From: Armin [mailto:[EMAIL PROTECTED] Sent: Monday, December 29, 2003 2:45 PM To: [EMAIL PROTECTED] Subject: Re: generating GIFs Robert Brown wrote: > Andrew Gaffney writes: > > zentara wrote: > > > Well, gifs were

RE: techniques for handling large text files

2003-12-28 Thread Tom Kinzer
ut at me for I/O. Have you tried benchmark on it? -Tom Kinzer -Original Message- From: danl001 [mailto:[EMAIL PROTECTED] Sent: Sunday, December 28, 2003 10:06 PM To: [EMAIL PROTECTED] Subject: techniques for handling large text files Hi, If this question would be better posted to an

RE: How to count the size of files in a directory

2003-12-27 Thread Tom Kinzer
not sure if you meant except those that match...in that case, replace the if with unless. -Tom Kinzer -Original Message- From: danield [mailto:[EMAIL PROTECTED] Sent: Saturday, December 27, 2003 10:15 PM To: perl_beginer Subject: How to count the size of files in a directory Hello all

RE: Array Representation

2003-12-23 Thread Tom Kinzer
that says assign elements 12 through 24 of that array these values. element numbering in perl starts at zero, so 12 is the 13th element in the array. -Tom Kinzer -Original Message- From: Ursala Luttrell [mailto:[EMAIL PROTECTED] Sent: Tuesday, December 23, 2003 10:41 AM To: [EMAIL

RE: Align Text

2003-12-19 Thread Tom Kinzer
say wha? show me, please. -Original Message- From: Bill Jastram [mailto:[EMAIL PROTECTED] Sent: Friday, December 19, 2003 10:04 AM To: Tom Kinzer Cc: James Edward Gray II; Perl List Subject: RE: Align Text We're getting closer. But lets say the first name of the first field i

RE: Preventing Accidentally Fork Bombing My Box

2003-12-19 Thread Tom Kinzer
nope, looks like it's no safety net for CPU or anything, just compartmentalized namespace and such. -Tom Kinzer -Original Message- From: Tom Kinzer [mailto:[EMAIL PROTECTED] Sent: Friday, December 19, 2003 9:27 AM To: Dan Anderson; Perl Beginners Subject: RE: Preventing Accidentally

RE: Preventing Accidentally Fork Bombing My Box

2003-12-19 Thread Tom Kinzer
use safe ? just a guess if it will work for this problem. check it out. -Tom Kinzer -Original Message- From: Dan Anderson [mailto:[EMAIL PROTECTED] Sent: Friday, December 19, 2003 8:56 AM To: Perl Beginners Subject: Preventing Accidentally Fork Bombing My Box I'm creating an app

RE: Align Text

2003-12-19 Thread Tom Kinzer
yes, and if that won't work for you, check out the 'format' command, you can do lots of slick stuff with it, like centering. -Tom Kinzer -Original Message- From: James Edward Gray II [mailto:[EMAIL PROTECTED] Sent: Friday, December 19, 2003 9:16 AM To: Bill Jastram Cc: Pe

RE: how to remove a ^M charaters from a variable

2003-12-19 Thread Tom Kinzer
-platform weirdness on the end of your lines. -Tom Kinzer -Original Message- From: agftech lists [mailto:[EMAIL PROTECTED] Sent: Friday, December 19, 2003 9:00 AM To: [EMAIL PROTECTED] Subject: Re: how to remove a ^M charaters from a variable I'd found this here http://www.unixblo

RE: how to remove a ^M charaters from a variable

2003-12-19 Thread Tom Kinzer
right - my bad. what i mean, not what i say! thanks rob. -Tom Kinzer -Original Message- From: Rob Dixon [mailto:[EMAIL PROTECTED] Sent: Friday, December 19, 2003 3:07 AM To: [EMAIL PROTECTED] Subject: Re: how to remove a ^M charaters from a variable Tom Kinzer wrote: > >

RE: how to remove a ^M charaters from a variable

2003-12-19 Thread Tom Kinzer
tr/015//; -Tom Kinzer -Original Message- From: Randy W. Sims [mailto:[EMAIL PROTECTED] Sent: Thursday, December 18, 2003 8:05 PM To: David Inglis Cc: [EMAIL PROTECTED] Subject: Re: how to remove a ^M charaters from a variable On 12/20/2003 8:21 AM, David Inglis wrote: > I am read

RE: script for passwd file

2003-12-16 Thread Tom Kinzer
we'll be curious to see what you come up with for a solution, rob. *and help if you get stuck* -Tom Kinzer -Original Message- From: rmck [mailto:[EMAIL PROTECTED] Sent: Tuesday, December 16, 2003 5:01 PM To: [EMAIL PROTECTED] Subject: script for passwd file Hi, I'm stuck

RE: Recommended simple Perl IDE/Editors ?

2003-12-15 Thread Tom Kinzer
I use the IDE OptiPerl and like it quite a bit. Vim is the best editor, IMHO. The Optiperl boys have added Vim OLE support to their list of enhancements. http://www.xarka.com/optiperl/index.html -Tom Kinzer -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent

RE: Recommended simple Perl IDE/Editors ?

2003-12-15 Thread Tom Kinzer
OptiPerl rocks. http://www.xarka.com/optiperl/index.html -Tom Kinzer -Original Message- From: Randy W. Sims [mailto:[EMAIL PROTECTED] Sent: Monday, December 15, 2003 2:22 PM To: Wiggins d Anconia Cc: Chuck Fox; [EMAIL PROTECTED]; [EMAIL PROTECTED] Subject: Re: Recommended simple Perl

RE: Parentheses

2003-12-12 Thread Tom Kinzer
as a matter of style, i think always having them is nice for maintenance/readability. -Tom Kinzer -Original Message- From: Rob Dixon [mailto:[EMAIL PROTECTED] Sent: Friday, December 12, 2003 8:08 AM To: [EMAIL PROTECTED] Subject: Re: Parentheses Paul Kraus wrote: > > Ok a

RE: Question for this Group ... dont flame me :)

2003-12-12 Thread Tom Kinzer
btw Jeff, good post. I think this will stimulate a good conversation. This is a common problem with lots of different workarounds. Thanks. -Original Message- From: Jeff Westman [mailto:[EMAIL PROTECTED] Sent: Friday, December 12, 2003 7:26 AM To: perl_help Subject: Question for this Gro

RE: Question for this Group ... dont flame me :)

2003-12-12 Thread Tom Kinzer
it: You can always install your own version of perl. You then have a few perl path issues to deal with, but you can put whatever modules you want in without mussing any of the "system" perl tools. -Tom Kinzer -Original Message- From: Jeff Westman [mailto:[EMAIL PROTECTED] Sent:

RE: Move a file

2003-12-12 Thread Tom Kinzer
u are logging your PID, or just figuring out which zombie process owns which file... it's a little more work to ignore, or you can use both ideas at the same time and ignore files starting with dot. -Tom Kinzer -Original Message- From: Wiggins d Anconia [mailto:[EMAIL PROTECTED] Se

RE: adding path to $PATH

2003-12-10 Thread Tom Kinzer
in korn it would be: export PATH=$(add_path):$PATH -Original Message- From: Robert Brown [mailto:[EMAIL PROTECTED] Sent: Wednesday, December 10, 2003 3:20 PM To: drieux Cc: Perl Perl Subject: Re: adding path to $PATH drieux writes: > > On Dec 9, 2003, at 10:09 PM, Pablo Cusnir wrote

RE: -e with single quotes

2003-12-10 Thread Tom Kinzer
Guessing here but maybe you don't want to use *Perl's* escape, but instead use your *shell's* escape. Whatchu running from? -Tom Kinzer -Original Message- From: Dan Muey [mailto:[EMAIL PROTECTED] Sent: Wednesday, December 10, 2003 3:05 PM To: beginners Subject: -e wit

RE: Match the first 3 characters of 2 words?

2003-12-10 Thread Tom Kinzer
perldoc -f substr would be one way. "easiest" is a loaded word, depends on the context and the individual... -Tom Kinzer -Original Message- From: Rod [mailto:[EMAIL PROTECTED] Sent: Wednesday, December 10, 2003 12:19 PM To: '[EMAIL PROTECTED]' Subject: Match the fir

RE: file path pattern matching problem.

2003-12-10 Thread Tom Kinzer
Yes! And use Basename too. these will also give you the advantage of making your programs more portable! -Tom Kinzer -Original Message- From: John W. Krahn [mailto:[EMAIL PROTECTED] Sent: Wednesday, December 10, 2003 11:37 AM To: [EMAIL PROTECTED] Subject: Re: file path pattern

RE: Help needed on perl wrappers

2003-12-10 Thread Tom Kinzer
wo columns into two frames, make 'em scrollable and bob's your uncle - you're done. Good luck, let us know what you end up with and how it worked for you. -Tom Kinzer -Original Message- From: Wiggins d Anconia [mailto:[EMAIL PROTECTED] Sent: Wednesday, December 10, 2003

RE: Help needed on perl wrappers

2003-12-09 Thread Tom Kinzer
he right column. More info please. -Tom Kinzer -Original Message- From: Pandey Rajeev-A19514 [mailto:[EMAIL PROTECTED] Sent: Tuesday, December 09, 2003 8:16 PM To: '[EMAIL PROTECTED]' Subject: Help needed on perl wrappers Hi, I have a text that I read from a file. I want to displ

RE: Pattern Match

2003-12-09 Thread Tom Kinzer
Rob, can you explain the details of that replace? That's pretty slick. I see you're adding the hex value to get to the appropriate ASCII value, but didn't know you could do some of that gyration inside a regex. Thanks. -Tom Kinzer -Original Message- From: Rob Dixon

RE: Reading a log file, again

2003-12-08 Thread Tom Kinzer
of info determine which is the right one. -Tom Kinzer -Original Message- From: R. Joseph Newton [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 7:02 PM To: Tom Kinzer Cc: Katka a Daniel Dunajsky; Beginners Perl Subject: Re: Reading a log file, again Tom Kinzer wrote: > Try t

RE: [OT] Education Level

2003-12-08 Thread Tom Kinzer
http://perlcert.perlocity.org/ -Original Message- From: J Ingersoll [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 4:16 PM To: Perl Beginner's List Subject: RE: [OT] Education Level --- Wiggins d Anconia <[EMAIL PROTECTED]> wrote: > > > > looking to break out of a > > non-c

RE: How to process multi-line records ?

2003-12-08 Thread Tom Kinzer
Nice. Don't forget to "get along well with the other children" by putting $/ back! -Tom Kinzer -Original Message- From: Kevin Pfeiffer [mailto:[EMAIL PROTECTED] Sent: Monday, December 08, 2003 1:52 PM To: [EMAIL PROTECTED] Subject: Re: How to process multi-line records ?

RE: Reading a log file, again

2003-12-08 Thread Tom Kinzer
Try this: Caveat: This all assumes LOTS about the format of your data being consistent, and so should be treated as a "quick and dirty" as opposed to anything resembling a robust application... I'm not sure what your intention with the script is, but is worth mentioning. -Tom K

RE: sorter script [was: Frustrated newbie question]

2003-12-07 Thread Tom Kinzer
*Consciously* making the decision that your script will no longer be portable... my $2Cents; -Tom Kinzer -Original Message- From: Bryan Harris [mailto:[EMAIL PROTECTED] Sent: Sunday, December 07, 2003 5:32 PM To: Beginners Perl Subject: Re: sorter script [was: Frustrated newbie question

RE: stripping last field of a carriage return

2003-12-07 Thread Tom Kinzer
Oops. 012. :( -Original Message- From: Tom Kinzer [mailto:[EMAIL PROTECTED] Sent: Sunday, December 07, 2003 9:41 PM To: R. Joseph Newton; Bryan Harris Cc: Beginners Perl Subject: RE: stripping last field of a carriage return 013 is line feed, aka "new line". -

RE: stripping last field of a carriage return

2003-12-07 Thread Tom Kinzer
Owen, I've had trouble doing this exact thing before with Perl regular expressions on AIX, I never got in and figured out what exactly was the root cause, but I just switched to the 'tr' command and it worked fine. Something to try. -Tom Kinzer -Original Message- Fro

RE: stripping last field of a carriage return

2003-12-07 Thread Tom Kinzer
013 is line feed, aka "new line". -Tom Kinzer -Original Message- From: R. Joseph Newton [mailto:[EMAIL PROTECTED] Sent: Sunday, December 07, 2003 7:24 PM To: Bryan Harris Cc: Beginners Perl Subject: Re: stripping last field of a carriage return Bryan Harris wrote: > >

RE: Reading from a log - still a problem

2003-12-07 Thread Tom Kinzer
ved a solution for my problem (reading from log) from Tom Kinzer. The code is: #!/usr/bin/perl -w use strict; my $log_file = "/appl/log/4e4d/20031130.txt"; open LOG, "< $log_file" or die "Could not open file $!"; while ( ) { chomp; if ( /^GTotal Content:/ ) {

RE: Reading from a log - still a problem

2003-12-07 Thread Tom Kinzer
lueCount, $lineCount); while ( ) { chomp; $lineCount++; if ( /^GTotal Content:/ ) { my ($gtotal_content, $value) = split(/:/, $_); printf "Value:%010\n", $value; $valueCount++; } } close LOG; print "Found a total of $valueCount values in $lineCount lines\n";

RE: How to process multi-line records ?

2003-12-07 Thread Tom Kinzer
ly: while ( ) until ( blankLine ) push into @thisChunk if ( criteria ) spit @thisChunk to fileA else spit @thisChunk to fileB } Kinda like that? Post some code and/or more specific requirements and I'm sure we can help. This is the beginner list so don't

RE: [OT] Education Level

2003-12-07 Thread Tom Kinzer
ile development methodologies? Not from going to school, that's for sure. What have you been doing for the last 4 years? That's what people care about. -Tom Kinzer -Original Message- From: Charles K. Clarkson [mailto:[EMAIL PROTECTED] Sent: Sunday, December 07, 2003 9:3

RE: Reading from log

2003-12-06 Thread Tom Kinzer
Typically I'm against just doing something for somebody, but you caught me at a good time. Here is an example to get you started: #!/usr/local/bin/perl -w use strict; my $input = shift; my $total; die "Usage: Arg1: Input File to Scan." unless $input; open IN, "< $input" or die "Unable to o

RE: formats

2003-12-05 Thread Tom Kinzer
To just use it for STDOUT, it's pretty straight forward, switching the special $~ variable as needed. You're switching FORMATs not filehandles. There may be a shortcut but this is how I would do it for this problem: -Tom Kinzer _ format TYPE_1 = Im formated

RE: Replacing text

2003-12-05 Thread Tom Kinzer
Good news, Dan. That is arguably one of Perl's most famous features! Regular expresions (Perl's own) are very similar to what you would do with sed, if you are familiar with that. open IN, "< $input" or die "Unable to open $input for reading, $!, stopped"; open OUT, "> $output" or die "Unable

RE: remove control chars

2003-12-04 Thread Tom Kinzer
Hah! I'm unemployed right now, so how about a contract?!? ;) --Tom Kinzer --Perl Gun for Hire-- -Original Message- From: Rob Dixon [mailto:[EMAIL PROTECTED] Sent: Thursday, December 04, 2003 8:56 AM To: [EMAIL PROTECTED] Subject: Re: remove control chars James Kipp wrote: >

RE: Beta Testing a Robot

2003-12-04 Thread Tom Kinzer
I also admire the effort and the good intentions, but, I think most Perl programmers can handle a Google search, and the bot just creates unnecessary traffic on the list. At a minimum, it should only send to the original poster, not the whole list. my $2Cents; -Tom Kinzer -- To

RE: Timing several processes

2003-12-03 Thread Tom Kinzer
ime. Of course, all this has very little to do with terminating a child at a certain time... -Tom Kinzer -Original Message- From: Akens, Anthony [mailto:[EMAIL PROTECTED] Sent: Wednesday, December 03, 2003 10:07 AM To: Akens, Anthony; Tom Kinzer; [EMAIL PROTECTED] Subject: RE: Timing se

RE: Timing several processes

2003-12-03 Thread Tom Kinzer
Right. POE may be a good tool for handling those children processes. (Instead of forking at all.) -Tom Kinzer -Original Message- From: Akens, Anthony [mailto:[EMAIL PROTECTED] Sent: Wednesday, December 03, 2003 9:58 AM To: Tom Kinzer; [EMAIL PROTECTED] Subject: RE: Timing several

RE: Timing several processes

2003-12-03 Thread Tom Kinzer
http://poe.perl.org Maybe this would be a good job for POE? -Tom Kinzer -Original Message- From: Akens, Anthony [mailto:[EMAIL PROTECTED] Sent: Wednesday, December 03, 2003 7:49 AM To: [EMAIL PROTECTED] Subject: Timing several processes Hi all! I'm wanting to write a simpl

RE: Reading files

2003-12-02 Thread Tom Kinzer
OK, but how about: 1)where is $LOG being set? 2)does it get past the dies shown below? 3)got strict? it's 'fer your own good, you know! ;) -Tom Kinzer #!/usr/bin/perl -w $file="./text"; $|=1; use Fcntl; use IO::Handle; $D_LOG = $ENV{MHCONTEXTFD}; open($LOG, "<

RE: Reading files

2003-12-02 Thread Tom Kinzer
I don't see $LOG being set...strict would catch that. -Tom Kinzer > Hello All, > I am trying to open a file once , and then duplicate it's > File Handle. I am trying to workout example straight from > FAQ5, with no luck. I will basicly trying to open a file, dup &

RE: Reading files

2003-12-02 Thread Tom Kinzer
start off by putting some "or die"s on those file opens. where are you breaking or what is the error message? not sure what the problem is exactly. -Tom Kinzer -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Tuesday, December 02, 2003 9:53 AM

RE: search and replace using regex

2003-12-02 Thread Tom Kinzer
You may want to start looking at some XML parsing modules, but assuming this is a quickie, I can point out that your problem is starting with the use of forward slash. Remember: your forward slash is your separator for the regular exp. Try replacing it with something else like | or % and go from

RE: breaking lines with perl

2003-12-02 Thread Tom Kinzer
QA checks out, it does work with the data supplied. (Naivete will have to checked with the real data.) You could add some nice indent formatting if you like by adding a tab to Jame's expression: s/\),\s*/),\n\t/ -Tom Kinzer -Original Message- From: James Edward Gray II [m

RE: Config file

2003-12-02 Thread Tom Kinzer
I've used Config::IniFiles before and it works very nice, especially nice if you do a tie into a hash for all your values. http://search.cpan.org/~wadg/Config-IniFiles-2.38/IniFiles.pm -Tom Kinzer -Original Message- From: Rod [mailto:[EMAIL PROTECTED] Sent: Tuesday, December 02,

RE: Encrypting PERL source code...

2003-12-01 Thread Tom Kinzer
even better, check out PAR: http://search.cpan.org/~autrijus/PAR/ -Tom Kinzer -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Monday, December 01, 2003 10:40 AM To: [EMAIL PROTECTED] Subject: Encrypting PERL source code... Can anyone suggest where I might

RE: OFF TOPIC: Unix in a Nutshell Orielly 3rd edition

2003-11-28 Thread Tom Kinzer
check out the O'Reilly Unix Bookshelf, you get a "in a nutshell" hard copy and 6 books in HTML on a cd. Makes a really great quick reference. I have the Perl and Linux/Webserver bookshelves as well. You can carry ~18 books around with you in your laptop case! -Tom Kinz

RE: Sockets and Daemonizing - was Re: Count the no of times a script is called

2003-11-27 Thread Tom Kinzer
Not sure, I'm not an admin by trade, but I was actually referring to the fact that some admins assume that user Perl processes that don't die, are doing so unintentionally. I'm sure there may also be security issues with the user/socket coding as well. --------- -T

RE: Count the no of times a script is called

2003-11-26 Thread Tom Kinzer
your sys admin is OK with this one. -Tom Kinzer Long Beach, CA -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]