CPAN force method question

2008-04-15 Thread Mathew
). Can I run CPAN::Shell::force(install,mod_name)? Would it be best to simply run CPAN::Module::force(install,mod_name)? Mathew -- JJ: I've lost faith in you Matt. Matt: What? JJ: You're listening to Metallica. Matt: Come on now, it isn't like I actually paid for it. Keep up with me and what I'm up

Re: Best way to grab lines n thru x of a file

2008-04-10 Thread Mathew
I think a simpler solution would be to use head and tail: head -n x file.txt tail -n x-n file.txt file2.txt Xavier Noria wrote: On Apr 10, 2008, at 18:24 , Jonathan Mast wrote: Hi, I have a ~125MB file of which I want to read lines n thru n+x and write those into a separate file. What

Time Comparison Easier Than I'm Making them

2007-11-28 Thread Mathew Snyder
' represents. All I'm trying to do is take the hh:mm:ss portion of each timestamp and find the difference yet I'm pulling my hair out trying to find the solution. Can someone please just point me to what I can use? I'll figure it out from there. Thanks Mathew -- Keep up with me and what I'm up to: http

Re: Building a string to contain a \

2007-11-17 Thread Mathew
You have to escape it with another backslash. 'C:\\ /S' Keep up with my goings on at http://theillien.blogspot.com AndrewMcHorney wrote: Hello I am trying to build a string that contains the following text dir c:\ /S so I can get a complete directory of all the files on drive C and put

Iterated Hash Names

2007-09-30 Thread Mathew Snyder
? Mathew -- Keep up with me and what I'm up to: http://theillien.blogspot.com -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/

User input: dates spanning multiple months

2007-09-10 Thread Mathew Snyder
running a foreach loop over them both. But then, how would I accommodate the varying number of days in each month? Any input will be appreciated. Thanks. Mathew -- Keep up with me and what I'm up to: http://theillien.blogspot.com -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional

Re: User input: dates spanning multiple months

2007-09-10 Thread Mathew Snyder
] Sent: 10 September 2007 14:33 To: 'Mathew Snyder'; 'Perl Beginners' Subject: AW: User input: dates spanning multiple months First I would use unix internal time format(epochen). And I would use Date-Calc (search.cpan.org/dist/Date-Calc/), Date-Calendar. This should solve nearly all of your

Re: User input: dates spanning multiple months

2007-09-10 Thread Mathew Snyder
Chas Owens wrote: On 9/10/07, Mathew Snyder [EMAIL PROTECTED] wrote: I have a script which has to be manually edited to run for a span of days. When these days are over several weeks it can be clearly tedious to enter dates in -mm-dd format. I've decided to set it up to ask for user

More Perl and AJAX

2007-08-29 Thread Mathew Snyder
When passing a value from JavaScript to a Perl script, am I right in thinking that the value received by the Perl script would be captured like my $value = @_;? I'm trying to pass a value to Perl and by calling it directly in the browser and passing a value to it like so

Re: AW: More Perl and AJAX

2007-08-29 Thread Mathew Snyder
Nachricht- Von: Mathew Snyder [mailto:[EMAIL PROTECTED] Gesendet: Mittwoch, 29. August 2007 13:32 An: Perl Beginners Betreff: More Perl and AJAX When passing a value from JavaScript to a Perl script, am I right in thinking that the value received by the Perl script would be captured

Perl and AJAX

2007-08-27 Thread Mathew Snyder
if needed. Mathew -- Keep up with me and what I'm up to: http://theillien.blogspot.com -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/

Re: Perl and AJAX

2007-08-27 Thread Mathew Snyder
Paul Lalli wrote: On Aug 27, 8:43 am, [EMAIL PROTECTED] (Mathew Snyder) wrote: Let's forget for a moment that CGI::Ajax exists. Instead, imagine that all I want to do is call a Perl script from my AJAX application. Having created all the necessary communication lines I then pass the script

Re: Perl and AJAX

2007-08-27 Thread Mathew Snyder
Paul Lalli wrote: On Aug 27, 8:43 am, [EMAIL PROTECTED] (Mathew Snyder) wrote: Let's forget for a moment that CGI::Ajax exists. Instead, imagine that all I want to do is call a Perl script from my AJAX application. Having created all the necessary communication lines I then pass the script

Re: Help needed with insignificant problem using format and write

2007-08-21 Thread Mathew Snyder
Chas Owens wrote: On 8/20/07, Mathew Snyder [EMAIL PROTECTED] wrote: Paul Lalli wrote: On Aug 20, 3:10 pm, [EMAIL PROTECTED] (Mathew Snyder) wrote: I run a script which creates a small report for different users of a system we have here at work. The report is a simple text document

Re: Help needed with insignificant problem using format and write

2007-08-21 Thread Mathew Snyder
Chas Owens wrote: On 8/21/07, Mathew Snyder [EMAIL PROTECTED] wrote: snip It would appear that for all but the first iteration, this is happening. However, something during the first time through seems to cause the flag to not be what it should. I've tried changing where the TOP

Help needed with insignificant problem using format and write

2007-08-20 Thread Mathew Snyder
--- 81106 Ticket Subject 08-13-2007 0:20 end output It gets that double header. Again, everything else gets only the one, expected, header. Anyone have any ideas as to why the first one always prints twice? Mathew

Re: Help needed with insignificant problem using format and write

2007-08-20 Thread Mathew Snyder
Paul Lalli wrote: On Aug 20, 3:10 pm, [EMAIL PROTECTED] (Mathew Snyder) wrote: I run a script which creates a small report for different users of a system we have here at work. The report is a simple text document formated with, of all things, the format function. It uses a TOP to create

Re: Format Question

2007-08-16 Thread Mathew Snyder
Tom Phoenix wrote: On 8/15/07, Mathew Snyder [EMAIL PROTECTED] wrote: How would I go about sub-listing something. For instance, if I have a work order that has been worked on during different days, I want to list the work order once and each day below it. It would look like this: Ticket

Format Question

2007-08-15 Thread Mathew Snyder
successive line. How would I do this with format? Would I need two different formats? One for the first line and another for each subsequent line? Thanks Mathew -- Keep up with me and what I'm up to: http://theillien.blogspot.com -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional

qw with strings containing spaces

2007-08-09 Thread Mathew Snyder
on PerlMonks and saw a solution which created a scalar with a string containing each item separated by commas. It is then run through the split() function using the commas as the delimiter. I'd like a more succinct and cleaner method of doing this though, if possible. Any ideas? Mathew -- Keep

GD::Graph

2007-07-15 Thread Mathew
Is this module really as simple as it appears? -- Keep up with my goings on at http://theillien.blogspot.com -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/

Re: Problem with runaway format

2007-07-04 Thread Mathew Snyder
Tom Phoenix wrote: On 7/2/07, Mathew [EMAIL PROTECTED] wrote: foreach my $date (@searchDate) { while (my $ticket = $tix-Next) { Seeing this worries me. I don't know enough about what's going on to tell whether it's wrong or not, but it looks wrong. When the outer loop goes

Re: Problem with runaway format

2007-07-04 Thread Mathew Snyder
Tom Phoenix wrote: On 7/2/07, Mathew [EMAIL PROTECTED] wrote: foreach my $date (@searchDate) { while (my $ticket = $tix-Next) { Seeing this worries me. I don't know enough about what's going on to tell whether it's wrong or not, but it looks wrong. When the outer loop goes

Re: Problem with runaway format

2007-07-02 Thread Mathew
kens wrote: On Jul 1, 5:40 am, [EMAIL PROTECTED] (Mathew Snyder) wrote: I have a script which places data 4 levels deep in a HoHoHoH. It grabs tickets in our ticket system using the systems API and places attributes about each piece of activity into the hash. The has is called %tickets

Re: Problem with runaway format

2007-07-02 Thread Mathew
Tom Phoenix wrote: On 7/1/07, Mathew Snyder [EMAIL PROTECTED] wrote: The problem didn't surface until I went from using the %tikSubj hash seen near the top of the code snippet to a multi-level hash. But then, using %tikSubj presents its own bug for some reason. One tricky bit about

Re: Problem with runaway format

2007-07-02 Thread Mathew
Tom Phoenix wrote: On 7/2/07, Mathew [EMAIL PROTECTED] wrote: foreach my $date (@searchDate) { while (my $ticket = $tix-Next) { Seeing this worries me. I don't know enough about what's going on to tell whether it's wrong or not, but it looks wrong. When the outer loop goes

AJAX, Graphs and Perl backend

2007-07-01 Thread Mathew Snyder
Does anyone know what the best route to creating graphs using AJAX and Perl would be? I've been running various searches on this and haven't found any solid information on how to make this happen. Thanks Mathew -- Keep up with me and what I'm up to: http://theillien.blogspot.com

Problem with runaway format

2007-07-01 Thread Mathew Snyder
the intricacies of the system I'm working with, I won't be sad if no one has any input ;). Thanks Mathew -- Keep up with me and what I'm up to: http://theillien.blogspot.com -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/

Re: Problem with runaway format

2007-07-01 Thread Mathew
:D Funny you should say that... Actually, all the data is being pulled in from a database already. Keep up with my goings on at http://theillien.blogspot.com Ken Foskey wrote: On Sun, 2007-07-01 at 05:40 -0400, Mathew Snyder wrote: I have a script which places data 4 levels deep in a HoHoHoH

Re: AJAX, Graphs and Perl backend

2007-07-01 Thread Mathew
cldmismgr wrote: On Jul 1, 1:05 am, [EMAIL PROTECTED] (Mathew Snyder) wrote: Does anyone know what the best route to creating graphs using AJAX and Perl would be? I've been running various searches on this and haven't found any solid information on how to make this happen. Thanks Mathew

Re: using a homemade perl module

2007-06-30 Thread Mathew Snyder
Mumia W. wrote: On 06/28/2007 10:22 PM, Mathew Snyder wrote: I'm getting a strange bit of behaviour. I have everything set up right and my dates are getting made up properly however, one sub which creates the searchDate array isn't being called. I have to enter the full module path

Re: using a homemade perl module

2007-06-28 Thread Mathew Snyder
Brad Baxter wrote: On Jun 14, 10:22 pm, [EMAIL PROTECTED] (Mathew Snyder) wrote: I fixed all of the bugs save one. I can't access any of my subroutines without explicitly using it with dates_emails::subroutine. I was under the impression that if I was exporting them all from the module

Re: using a homemade perl module

2007-06-28 Thread Mathew Snyder
Paul Johnson wrote: On Thu, Jun 28, 2007 at 06:58:36AM -0500, Mumia W. wrote: On 06/28/2007 03:00 AM, Mathew Snyder wrote: our @ISA = qw(Exporter); our @EXPORT = qw(startDate endDate searchStart searchEnd); our $VERSION = '1'; Those lines need to be within a BEGIN

Re: using a homemade perl module

2007-06-28 Thread Mathew Snyder
Paul Johnson wrote: On Thu, Jun 28, 2007 at 06:58:36AM -0500, Mumia W. wrote: On 06/28/2007 03:00 AM, Mathew Snyder wrote: our @ISA = qw(Exporter); our @EXPORT = qw(startDate endDate searchStart searchEnd); our $VERSION = '1'; Those lines need to be within a BEGIN

Re: Proper class setup?

2007-06-24 Thread Mathew Snyder
Chas Owens wrote: On 6/22/07, Mathew Snyder [EMAIL PROTECTED] wrote: snip I'm not sure what you mean by Change your new() in a new() and init(). snip What do you mean by set/get approach? snip Some people believe that new should just create a new blank object and call an init method

problem with readline

2007-06-23 Thread Mathew Snyder
. Thanks Mathew #!/usr/bin/perl use strict; use warnings; use DBI; my $message = You are receiving this message in response to an email you . sent to [EMAIL PROTECTED] The email address you sent . from is not currently in our records. To have the action you . need performed, please

Re: nevermind

2007-06-23 Thread Mathew Snyder
You'll notice in the section that creates the filehandle I have a statement that says next if $address =~ m/^#/gmx;. I had to escape the #. Can anyone tell me why that is? It isn't a special character for regexes that I've ever seen used. Thanks, Mathew -- Keep up with me and what I'm up

Re: problem with readline

2007-06-23 Thread Mathew
Tom Phoenix wrote: On 6/23/07, Mathew Snyder [EMAIL PROTECTED] wrote: foreach my $address (readline AUTHFILE){ chomp($address); next if $address =~ m/^#/gmx; The author of that code probably doesn't know what /g, /m, and /x do for a pattern match. When you know how to use them

Re: nevermind

2007-06-23 Thread Mathew
Actually, I didn't write the code. It was written by someone else whom no longer works at our company. Keep up with my goings on at http://theillien.blogspot.com Paul Lalli wrote: On Jun 23, 4:18 am, [EMAIL PROTECTED] (Mathew Snyder) wrote: You'll notice in the section that creates

Proper class setup?

2007-06-22 Thread Mathew Snyder
print { my ($self) = @_; # Print Report info print $self-id . . $self-queue . \n; } 1; Mathew -- Keep up with me and what I'm up to: http://theillien.blogspot.com -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http

Re: Proper class setup?

2007-06-22 Thread Mathew Snyder
Dr.Ruud wrote: Mathew Snyder schreef: I'm presently learning OOP as Perl does it using online resources and and Programming Perl as my tutors. I'm not certain I have it right though. Is this correct for the package: [whitespace is cheap] Duly noted :D package Report; require

Alternatives to highly nested hashes

2007-06-20 Thread Mathew Snyder
a hash like that? Mathew -- Keep up with me and what I'm up to: http://theillien.blogspot.com -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/

Re: Alternatives to highly nested hashes

2007-06-20 Thread Mathew Snyder
(attrib1 = value, attrib2 = value, attrib3 = value)? Or would I create the instance as above and then populate it by some other means? For instance $instance-hashOfAttribs { attrib1 = value, attrib2 = value, attrib3 = value }; Am I at least on the right track? Mathew Keep up with me

Re: Alternatives to highly nested hashes

2007-06-20 Thread Mathew
Rob Dixon wrote: Mathew Snyder wrote: It looks like an object is what I want. Am I correct? Suppose I need to work with a bit of data that actually has 11 attributes. This would be an object of another type. However, I need to manipulate pieces of it differently. So I'm guessing I

Re: value of variable switches from ' ' to 'value'

2007-06-17 Thread Mathew Snyder
Mumia W. wrote: On 06/17/2007 12:36 AM, Mathew Snyder wrote: [...] In the debugger I've set the 'w' command to watch the variable containing the day being looked for ($day). I would have thought $day stays the same throught an iteration of the while loop but the debugger keeps stopping

value of variable switches from ' ' to 'value'

2007-06-16 Thread Mathew Snyder
you can offer will be appreciated Mathew -- Keep up with me and what I'm up to: http://theillien.blogspot.com weekly_timesheet.pl Description: Perl program -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/

Re: using a homemade perl module

2007-06-14 Thread Mathew Snyder
That worked. Thanks. Now I just need to figure out all of the undeclared variables ;) Mathew Keep up with me and what I'm up to: http://theillien.blogspot.com Martin Barth wrote: Hi, try: use lib /usr/local/bin/lib/; use dates_email; HTH Martin On Thu, 14 Jun 2007 01:50:57 -0400

Hash Key is a Null Value

2007-06-14 Thread Mathew Snyder
probably reassign it through more complicated means but that would require creating objects and accessing methods I'm not familiar with. If anyone knows an easier way to access a null key I'd appreciate hearing it. Thanks Mathew -- Keep up with me and what I'm up to: http://theillien.blogspot.com

Re: Hash Key is a Null Value

2007-06-14 Thread Mathew
Looks like there's an extra single quote after Dumper(\%h); Keep up with my goings on at http://theillien.blogspot.com Xu, Lizhe wrote: On Jun 14, 8:50 am, [EMAIL PROTECTED] (Chas Owens) wrote: To force Data::Dumper to do the right thing for the display you must set $Data::Dumper::Useqq to 1.

Re: Hash Key is a Null Value

2007-06-14 Thread Mathew
had not been set instead of just leaving a big ugly blank spot. Keep up with my goings on at http://theillien.blogspot.com Chas Owens wrote: On 6/14/07, Mathew Snyder [EMAIL PROTECTED] wrote: I'm building a hash using values from a database backend to an application we use in house

Re: Hash Key is a Null Value

2007-06-14 Thread Mathew
Erk...nevermind. didn't realize that was a continuance from the line above it. Keep up with my goings on at http://theillien.blogspot.com Xu, Lizhe wrote: On Jun 14, 8:50 am, [EMAIL PROTECTED] (Chas Owens) wrote: To force Data::Dumper to do the right thing for the display you must set

Re: Hash Key is a Null Value

2007-06-14 Thread Mathew Snyder
I did this and set $Data::Dumper::Useqq = 1; this was the result: $VAR1 = { = 7, }; Nothing there. Does this mean I just have an empty string with neither a NUL value or anything else for that matter (physicists would be boggled ;) )? Mathew Keep up with me and what I'm up

Re: Hash Key is a Null Value

2007-06-14 Thread Mathew Snyder
Sure enough. I must have typo'ed it before. Now it works just like you say it should. Thanks Mathew Keep up with me and what I'm up to: http://theillien.blogspot.com Chas Owens wrote: On 6/14/07, Mathew Snyder [EMAIL PROTECTED] wrote: I did this and set $Data::Dumper::Useqq = 1

Re: using a homemade perl module

2007-06-14 Thread Mathew Snyder
. I've got this in my opening block: use lib '/usr/local/bin/lib/'; use dates_emails; Any thoughts? Mathew Keep up with me and what I'm up to: http://theillien.blogspot.com Martin Barth wrote: Hi, try: use lib /usr/local/bin/lib/; use dates_email; HTH Martin On Thu, 14 Jun 2007 01

using a homemade perl module

2007-06-13 Thread Mathew Snyder
script or do I have to use a different variable? All this homemade module stuff is new to me so I need help sorting through it. Thanks Mathew -- Keep up with me and what I'm up to: http://theillien.blogspot.com -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL

Re: using a homemade perl module

2007-06-13 Thread Mathew Snyder
/dates_email.pm qw/startDate/'; use '/usr/local/bin/lib'; Each one gives me the error Undefined subroutine dates_emails::startDate called at ./created_tickets.pl line 19.. Anyone know what I'm doing wrong? Mathew Keep up with me and what I'm up to: http://theillien.blogspot.com -- To unsubscribe, e-mail

Effective date grab

2007-05-31 Thread Mathew Snyder
about how many days the month has? Mathew -- Keep up with me and what I'm up to: http://theillien.blogspot.com -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/

Re: Effective date grab

2007-05-31 Thread Mathew Snyder
an array of 28/29, 30 or 31 dates. Mathew Keep up with me and what I'm up to: http://theillien.blogspot.com Mathew Snyder wrote: A while ago I had posted requesting help with a long block of code that would do all kinds of stuff dealing with the date. It turned out to not work despite being

YARQ: Yet Another Regex Question

2007-05-16 Thread Mathew Snyder
will be used as the value. The contents of (\w) in this case. Is that correct? Mathew -- Keep up with me and what I'm up to: http://theillien.blogspot.com -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/

Re: Can't sort error out; strict refs

2007-05-16 Thread Mathew
Rob Dixon wrote: Mathew Snyder wrote: I'm passing two hash references into a subroutine. One hash is in the format of $dept{$env}{$user}. This contains an amount of time spent by each user on a customer ($env). The second hash is in the format of $ticCount{$env}{$user}{$ticID

Re: YARQ: Yet Another Regex Question

2007-05-16 Thread Mathew
Chas Owens wrote: On 5/16/07, Mathew Snyder [EMAIL PROTECTED] wrote: I have a trouble ticket application that uses a regex to find a piece of information in an incoming email and auto populate a field if it is found. The line it will be looking for is CUSTOMER ENVIRONMENT customer_name

Re: YARQ: Yet Another Regex Question

2007-05-16 Thread Mathew
Chas Owens wrote: On 5/16/07, Mathew [EMAIL PROTECTED] wrote: snip What does gr() do? Mathew qr not gr. It is the quote regex operator. from perldoc perlop qr/STRING/imosx This operator quotes (and possibly compiles) its STRING as a regular

Thoughts on comments

2007-05-14 Thread Mathew Snyder
Is it possible to use too many comments? I'm looking at a script I wrote and think I may have made it less clear by trying to make it more clear. -- Keep up with me and what I'm up to: http://theillien.blogspot.com -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail:

Can't sort error out; strict refs

2007-05-14 Thread Mathew Snyder
]; } } } return %userAvg; } I've run this in the debugger and when I get to the line which assigns $ticCount I try to print it out and it's just blank. If I keep hitting enter it just returns to a blank line. I get the error when I continue to the next line with 'c'. Mathew -- Keep up with me and what

Stuck on a hash referrence, kinda

2007-05-13 Thread Mathew Snyder
A subroutine I'm working on takes two hash references. The hashes are each actually a HoH. timesheet(\%opsTotal, \%opsEnvTotal); The problem I'm having is that I need to look past the first hash and into the second for the existence of a particular key. I'm not sure how to go about doing this.

Re: Stuck on a hash referrence, kinda

2007-05-13 Thread Mathew Snyder
That's the problem. 'user' isn't in the first hash. It's in the second hash. The hash looks like $dept{customer}{user}. I need to skip $dept{customer} and check for $dept{customer}{user}. Mathew Keep up with me and what I'm up to: http://theillien.blogspot.com [EMAIL PROTECTED] wrote: Hi

Re: Stuck on a hash referrence, kinda

2007-05-13 Thread Mathew Snyder
problem. In General if you want to check the existence of the key user in the first hash, you can use the following if ($dept and exists($dept-{user}){ }else{} Hope that helps Yaron Kahanovitch - Original Message - From: Mathew Snyder [EMAIL PROTECTED] To: Perl

Re: Stuck on a hash referrence, kinda

2007-05-13 Thread Mathew Snyder
the following: if ($dept and exists($dept-{customer}{user}){ }else{} Yaron Kahanovitch - Original Message - From: Mathew Snyder [EMAIL PROTECTED] To: [EMAIL PROTECTED] Cc: Perl Beginners beginners@perl.org Sent: Sunday, May 13, 2007 10:22:53 AM (GMT+0200) Auto-Detected Subject: Re

Re: Stuck on a hash referrence, kinda

2007-05-13 Thread Mathew
Rob Dixon wrote: Mathew Snyder wrote: [EMAIL PROTECTED] wrote: Mathew Snyder wrote: A subroutine I'm working on takes two hash references. The hashes are each actually a HoH. timesheet(\%opsTotal, \%opsEnvTotal); The problem I'm having is that I need to look past the first hash

Re: Stuck on a hash referrence, kinda

2007-05-13 Thread Mathew Snyder
That's waaay over my head. The method I used works so I'll stick with that. Thanks though. :) Keep up with me and what I'm up to: http://theillien.blogspot.com Chas Owens wrote: My understanding of the problem: You have a ref to a HoH and you need to find all of the first set of

passing two hashes into a subroutine

2007-05-12 Thread Mathew Snyder
When passing two hashes into a subroutine how do I use them separately if they are placed into one flat list? Mathew -- Keep up with me and what I'm up to: http://theillien.blogspot.com -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http

Re: passing two hashes into a subroutine

2007-05-12 Thread Mathew Snyder
-{$name}}; } printf TIMESHEET (- x 30); print TIMESHEET \n; printf TIMESHEET %18s\n\n, $env-{$environ}; } close TIMESHEET; } Does that look right? Mathew Keep up with me and what I'm up to: http://theillien.blogspot.com

Re: file lists and diffs?

2007-05-04 Thread Mathew Snyder
unfortunately, no. It has predetermined file locations spread across the drive Mathew Rodrick Brown wrote: On 5/3/07, Mathew Snyder [EMAIL PROTECTED] wrote: I have been given a task of installing a piece of backup software, then tarring up all of the associated files in order to automate

Re: file lists and diffs?

2007-05-04 Thread Mathew Snyder
Thanks for all the input. I've found that the program puts most of its files in one location and only a few in one other. I don't actually need to worry about this anymore as the tar command isn't as long as I thought it would be. Mathew Mathew Snyder wrote: I have been given a task

Text Formatters

2007-05-04 Thread Mathew Snyder
command that uses a call to one of the formatting methods? Any help would be appreciated. Thanks Mathew -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/

Re: Text Formatters

2007-05-04 Thread Mathew Snyder
John W. Krahn wrote: Mathew Snyder wrote: Question regarding the text formatting modules out there. I've found three on CPAN that seem to have the functionality that I'm looking for but I don't know which would best suit my needs. The three are Text::Format, Text::Wrapper and Text

Re: Text Formatters

2007-05-04 Thread Mathew Snyder
John W. Krahn wrote: Mathew Snyder wrote: Thanks for enlightening me about 'format' I've run your example code from the command line and got exactly the results you did (not that I'd expect to get anything different ;) ). I then attempted to incorporate the idea into my script: foreach

file lists and diffs?

2007-05-03 Thread Mathew Snyder
of a module I should look at to achieve this? Mathew -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/

Re: email text

2007-04-28 Thread Mathew
I'm sending. The data looks like this: Ticket IDhh:mm - 0000:00 1111:11 2222:22 And so on. That is what gets placed in the file but I'd prefer it be placed inside the email. Mathew Nigel Peck wrote: Mathew wrote: I have

Re: email text

2007-04-28 Thread Mathew
I'll have to look at the HEREDOC option. I'm not familiar with that. As for HTML, people here get quite frisky when they don't get plain text emails. Mathew Robert Hicks wrote: I typically use a HEREDOC to format my email messages. You can do all sort of things by sending the email as HTML

Re: hash referrences and such

2007-03-25 Thread Mathew Snyder
Chad Kemp wrote: Mathew, try to test every condition going INTO the hash (or hashes) before you actually assign a value to a key. as mentioned earlier, hashes must be key/value pairs. the key will auto-vivify if a key is new but only if a corresponding value accompanies it. when you

Re: hash referrences and such

2007-03-22 Thread Mathew Snyder
the %timeworked hash populated the way I need and paired with the %environment hash properly. Your further assistance will be greatly appreciated. Mathew -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/

Re: hash referrences and such

2007-03-21 Thread Mathew Snyder
Rob Dixon wrote: Mathew Snyder wrote: I have a problem printing out a hash. This is the script I'm working with: #!/usr/bin/perl use warnings; use strict; use lib '/usr/local/rt-3.6.3/lib'; use lib '/usr/local/rt-3.6.3/local/lib'; use RT; use RT::Tickets; RT::LoadConfig(); RT::Init

Re: hash referrences and such

2007-03-21 Thread Mathew Snyder
Chas Owens wrote: On 3/21/07, Mathew Snyder [EMAIL PROTECTED] wrote: snip my %customer = ${customer}; snip Hashes cannot be created with only one value, they must always be in pairs: key and value. If $customer has a type of HASH (you can put print ref($customer), \n

hash referrences and such

2007-03-20 Thread Mathew Snyder
simply print out the reference. I'm not even sure I'm doing the $timeworked = line correctly. Can someone help me out with this please? Thanks Mathew -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/

Re: hash referrences and such

2007-03-20 Thread Mathew Snyder
Also, I've read the *perldsc* perldoc and it didn't help undo my confusion. If we don't protect the freedom of speech, how will we know who the assholes are? http://theillien.blogspot.com Mathew Snyder wrote: I have a problem printing out a hash. This is the script I'm working with: #!/usr

Re: hash referrences and such

2007-03-20 Thread Mathew Snyder
Also, I've read the *perldsc* perldoc and it didn't help undo my confusion. Mathew Mathew Snyder wrote: I have a problem printing out a hash. This is the script I'm working with: #!/usr/bin/perl use warnings; use strict; use lib '/usr/local/rt-3.6.3/lib'; use lib '/usr/local/rt-3.6.3

Re: hash referrences and such

2007-03-20 Thread Mathew Snyder
. It may change to: print $key . - . $env-{$key} . \n; That isn't working either. It is complaining about $env not being declared. I replaced it with %{env}-{$key} but it said it was deprecated. It then proceeded to print out the references. Mathew -- To unsubscribe, e-mail: [EMAIL PROTECTED

Re: hash referrences and such

2007-03-20 Thread Mathew Snyder
anything I do there. Mathew -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/

Re: hash referrences and such

2007-03-20 Thread Mathew Snyder
Rob Dixon wrote: Mathew Snyder wrote: I have a problem printing out a hash. This is the script I'm working with: #!/usr/bin/perl use warnings; use strict; use lib '/usr/local/rt-3.6.3/lib'; use lib '/usr/local/rt-3.6.3/local/lib'; use RT; use RT::Tickets; RT::LoadConfig(); RT::Init

Re: hash referrences and such

2007-03-20 Thread Mathew Snyder
Chas Owens wrote: On 3/20/07, Mathew Snyder [EMAIL PROTECTED] wrote: snip $timeworked = $env{$transaction-Creator}{$transaction-TimeTaken}; snip From this line you can see that %env is a HoH (hash of hashes). This means that if you want to print it out you need two loops

What are the brackets used for

2007-03-14 Thread Mathew Snyder
my $timeworked = {}; Mathew -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/

Re: What are the brackets used for

2007-03-14 Thread Mathew Snyder
Thanks. That's what I thought it was doing but wasn't sure. Mathew John W. Krahn wrote: Mathew Snyder wrote: my $timeworked = {}; In this context they represent an anonymous hash, the reference of which is assigned to the scalar variable. It is usually not necessary because

Question about system call

2007-03-12 Thread Mathew
of trying to find a way to get the former to work. I'm just wondering what might have caused it to not work. Mathew -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/

Off-Topic: Is the Randall Schwartz of Perl Fame?

2007-03-05 Thread Mathew
http://articles.techrepublic.com.com/2100-1009_11-6164113.html?tag=nl.e019 Mathew -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/

Re: Off-Topic: Is the Randall Schwartz of Perl Fame?

2007-03-05 Thread Mathew
Well in that case, congratulations Randal Mathew Ovid wrote: --- Mathew [EMAIL PROTECTED] wrote: http://articles.techrepublic.com.com/2100-1009_11-6164113.html?tag=nl.e019 Mathew Yes, it's the same one. Oregon computer crime laws are such a pitiful joke that if I tell you

system and list of arguments

2007-02-20 Thread Mathew Snyder
,--plugin for the first section there, however, would the last part be \'Tickets==arg1,desc;arg2,desc;arg3,desc\') or would I have to break those down into separate arguments? Mathew -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/

Re: system and list of arguments

2007-02-20 Thread Mathew Snyder
Tom Phoenix wrote: On 2/20/07, Mathew Snyder [EMAIL PROTECTED] wrote: shredder --force --plugin 'Tickets=arg1,desc;arg2,desc;arg3,desc' I can see that the system call would look like system(shredder,--force,--plugin for the first section there, however, would the last part be \'Tickets

Re: Please help with convoluted script

2007-02-11 Thread Mathew Snyder
Tom Phoenix wrote: On 2/9/07, Mathew [EMAIL PROTECTED] wrote: I'm running this as a cron job 1 minute after midnight on Saturday nights (Sunday morning) so as to cover all of Saturday back through the previous Sunday. Does your suggestion mean I'd have to run it late Sunday night in order

Re: Please help with convoluted script

2007-02-11 Thread Mathew Snyder
; -- Jeff Pang EMAIL: [EMAIL PROTECTED] AIM: jeffpang I need to make sure $day and $month are in 2-digit format so that wouldn't work. At least, not anyway I'm presently familiar with. I tried to use sprintf in there but it failed because of not enough arguments. Mathew

  1   2   >