Re: IO::Socket::Multicast::mcast_send

2020-04-05 Thread James Kerwin
) work now! Thanks for the help. James On Sun, Apr 5, 2020 at 4:03 PM Shlomi Fish wrote: > Hi James, > > On Sun, 5 Apr 2020 14:58:26 +0100 > James Kerwin wrote: > > > Hi All, > > > > I'm trying to connect to a smart bulb on my home WIFI using mcast_send >

Re: IO::Socket::Multicast::mcast_send

2020-04-05 Thread James Kerwin
ve just quickly looked through the script on the laptop with the debugger. I'll go check with the pi when I can get back on it (plugged in to TV, Tv in use). 4) Mentioned this in 1. I'll keep at it for now, and keep trying things. I am able to identify the bulb when I log into the rou

IO::Socket::Multicast::mcast_send

2020-04-05 Thread James Kerwin
die "" so I can be certain it's failing at that point. I get the output "" (makes it easier to spot). I've just used a command recently that allows me to access the specific ip and port of the lamp and it indicates the connection is successful. I'm out of ideas and if anyone can advise I'd appreciate it. Slightly (very) out of my depth when it comes to ports and IPs etc. Thanks, James

Re: Google Sheets API Data Structure

2019-08-16 Thread James Kerwin
see if there's any module/function I could create that could get help me, but I think I may need to admit that it's quite a bit beyond me. Thanks, James

Google Sheets API Data Structure

2019-08-15 Thread James Kerwin
nyone help me untangle this? My spreadsheet has five worksheets and there are five lines in my output so my assumption is that each line represents a sheet. Any advice/help/guidance would be greatly appreciated. Thanks, James

Re: Install Problems: Net::Google::Spreadsheets

2019-08-08 Thread James Kerwin
stuck in a similar way: https://www.perlmonks.org/?node_id=11104105 Thanks, James On Thu, Aug 8, 2019 at 5:16 AM Mike wrote: > > I believe somebody else responded to this, but . . . > > I'll help if I can. > If you want me to try to install Net::Google::Spreadsheets > I can.

Re: Install Problems: Net::Google::Spreadsheets

2019-08-07 Thread James Kerwin
ht just be a waste of time. Thanks, James # Failed test at t/04_auth/04_oauth2.t line 72. # Structures begin differing at: # $got->{hd} = '' # $expected->{hd} = Does not exist # Failed test at t/04_auth/04_oauth2.t line 101. # Structures begin differing

Install Problems: Net::Google::Spreadsheets

2019-08-05 Thread James Kerwin
oogle-Spreadsheets-V4-0.002.tar.gz Has already been unwrapped into directory /home/james/.cpan/build/Net-Google-Spreadsheets-V4-0.002-gyJS1X HIROSE/Net-Google-Spreadsheets-V4-0.002.tar.gz Has already been prepared Running Build for H/HI/HIROSE/Net-Google-Spreadsheets-V4-0.002.tar.gz Warning:

Website Files Preview as Thumbnail

2019-04-26 Thread James Kerwin
is there a helpful Perl module/library that I can use? Thanks, James

Data::Dumper Output

2019-01-25 Thread James Kerwin
contains some sort of XML that I'm going to have to "crawl" along to get to what I want. Thanks, James

Re: Syntax "||" before sub

2018-11-22 Thread James Kerwin
Hi Sebastian, Thanks for that info! It's much more thorough than what I discovered about this. I'll keep it in mind as I delve deeper... Thanks, James On Thu, Nov 22, 2018 at 1:58 PM James Kerwin wrote: > Ahhh sorrry to reply to my own post but I found this: > > https:

Re: Syntax "||" before sub

2018-11-22 Thread James Kerwin
t; is defined... which is not a problem for this list to solve! Thanks, James On Thu, Nov 22, 2018 at 1:48 PM James Kerwin wrote: > Hi All, > > I'm looking through some Perl files for software we use and I noticed this > in one of the config files: > > $c->{guess_doc

Syntax "||" before sub

2018-11-22 Thread James Kerwin
sub { My question is, what is the "||" doing in the first example? It would be useful to know before I go changing anything. My instinct is that it's an "or" but that really doesn't make sense in this context. I've attempted to Google this, but found no solid answer. Thanks, James

Perl Email and WuFoo Forms.

2018-10-02 Thread James Kerwin
herwise). Does anybody have any idea how I could go about this? I have access to a server in which to host scripts on etc. and I'm not necessarily looking for a hand-holding solution, just a nudge in the right direction would be brilliant. Thanks, James

Eclipse/Epic/PadWalker for Perl

2018-07-30 Thread James Kerwin
ould anybody be able to shed some light onto this? I should add that my scripts run in eclipse as expected. The debugging just doesn't seem to be behaving itself. Thanks, James

Re: Unfamiliar syntax

2018-07-23 Thread James Kerwin
Morning All, Thank you for the help, it's really useful and gives me plenty to look at. When you know what something is called (e.g. anonymous subroutines) it becomes much easier to look it up. Thanks, James On Fri, Jul 20, 2018 at 5:47 PM, Octavian Rasnita wrote: > *From:* Jame

Unfamiliar syntax

2018-07-20 Thread James Kerwin
l -w at the top and some use statements). I know it's very vague, but could anybody explain this syntax to me? My suspicion is that something else is calling the subroutines in this file? Am I at least on the right track? Thanks, James

nfqueue -> Net::Frame::Layer::ETH?

2017-06-11 Thread James
Net::DNS::Packet->new(\$data_obj); $dns_hdr = $dns_obj->header; @dns_qs = $dns_obj->question; if ($dns_hdr->rd) { $drop = "yes"; } if ($dns_hdr->qdcount == 1) { if ($dns_qs[0]->qname !~ /(firstdomain|seconddomain)\.com)$/i) { $drop = "yes"; }

nfqueue -> Net::Frame::Layer::ETH?

2017-06-10 Thread James
Net::DNS::Packet->new(\$data_obj); $dns_hdr = $dns_obj->header; @dns_qs = $dns_obj->question; if ($dns_hdr->rd) { $drop = "yes"; } if ($dns_hdr->qdcount == 1) { if ($dns_qs[0]->qname !~ /(firstdomain|seconddomain)\.com)$/i) { $drop = "yes"; }

Re: perl for machine learning

2017-02-11 Thread James Alton
t; to program ML in. (Hides a lot of the ugly bits. And with ML, there really are a lot of ugly bits. The interface in Keras is like: train this model with these layers, give me results with that trained model.) YMMV and I hope my experiences above saves you lots of potential wasted time and mone

Re: Script runs slower with better hardware

2016-06-02 Thread James Alton
p/Tutorial http://sandsoftwaresound.net/perf/perf-tut-count-hw-events/ James Alton On Thu, Jun 2, 2016 at 12:25 AM, David Emanuel da Costa Santiago < deman...@gmail.com> wrote: > > Hello James, > > The CPUs are > > Laptop CPU: i7 Q 720 > Desktop CPU: i5 6500T > > The re

Re: Script runs slower with better hardware

2016-06-01 Thread James Alton
e threaded jobs and faster at multi-threaded jobs (say a Core i7 3.2GHz). Is the program you're trying to run written in such a way as to take advantage of multi-threading? Was the benchmark you mentioned a single threaded or multi-threaded benchmark? Best wishes, James Alton On Wed, Jun 1

File Size Limit

2016-04-08 Thread James Kerwin
ly handle files of 5MB maximum. So I would like to be able to limit the file size and start a new one when it reaches (or comes close to) this limit. This would allow me to automate it rather than having to manually break the big files up before continuing. Thanks! James.

Re: Counter Help

2016-02-12 Thread James Kerwin
ood. I solemnly swear to properly learn hashes and use them (and to stop thinking of them as "weird"). Again, thank you for the help! It's very appreciated. James. On Tue, Feb 9, 2016 at 6:37 PM, Jim Gibson wrote: > > > On Feb 9, 2016, at 6:46 AM, James Kerwin wrote: >

Re: Counter Help

2016-02-09 Thread James Kerwin
(@other, (join "", $_,$ii)); }} foreach (@other){ print "$_\n"; } This gave me the desired output. Like I said, I'll investigate the other way later... Thanks, James. On Tue, Feb 9, 2016 at 2:22 PM, Jim Gibson wrote: > > > On Feb 9, 2016, at 6:08 AM, James Kerw

Counter Help

2016-02-09 Thread James Kerwin
hen taking action. I just can't get the logic right though. I keep getting them all numbered sequentially from 1 to 10 or they all end in "_2" or alternating "_1" and "_2" If anybody could shed even the smallest glimmer of light on how to solve this I'd be really grateful. Thanks, James.

Re: Perl CGI-html quotation marks

2014-07-04 Thread James Kerwin
t I hadn't closed the button THING with a ">". Apparently with that it's able to handle the single quotation marks. What a fool! Thanks, James. On Thu, Jul 3, 2014 at 5:23 PM, Uri Guttman wrote: > On 07/03/2014 12:16 PM, James Kerwin wrote: > >> Hello a

Perl CGI-html quotation marks

2014-07-03 Thread James Kerwin
email to the list then I apologise. Any help is greatly appreciated! Thanks, James.

Re: Brackets in scalar and array

2014-05-29 Thread James Kerwin
It seems so obvious now. Should possibly have just tested it myself before asking... Thank you all for the explanations! On 29 May 2014 21:36, "Jim Gibson" wrote: > > On May 29, 2014, at 1:20 PM, James Kerwin wrote: > > > Hello all, long time lurker, first time requ

Brackets in scalar and array

2014-05-29 Thread James Kerwin
d any light on this I'd be very grateful. Thanks, James.

Re: How Much is Too Much? (WAS: formatting a list)

2013-10-02 Thread James Griffin
* Shawn H Corey [2013-10-01 17:34:06 -0400]: > On Tue, 1 Oct 2013 14:14:16 -0700 > Charles DeRykus wrote: > > > I'm not bucking for "net nanny" but, while full solutions and > > follow-on discussions can be enlightening, I wonder if they're really > > advantageous to the OP. Not to embarrass a

Re: Hello

2013-07-12 Thread James Alton
use feature say; use Net::DNS; foreach (Net::DNS::Resolver->new->nameservers) { say; } James Alton 801-388-7497 On Fri, Jul 12, 2013 at 12:31 AM, Frank Vino wrote: > Could you please let me know the perl script how to find DNS IP address of > system.? > > Thanks, > -Vino >

Re: last

2013-06-17 Thread James Alton
use strict; use warnings; use autodie; my $counter = 0; while($counter < 8) { if($counter > 2) { print "if: " . $counter . "\n"; last; } else { print "else: " . $counter . "\n"; } $counter++; } Cheers,

Re: sha-2 sum of files?

2013-06-12 Thread James Alton
What is the reason for checking file hashes once a month? Are you just trying to do a basic sys admin task like ensuring system file integrity? No sense in reinventing the wheel. Look into tripwire. http://www.linuxjournal.com/article/8758 Cheers, James On Wed, Jun 12, 2013 at 2:27 AM, lee

Re: how to make perl program run continue when i press control+s to pause screen output

2013-06-05 Thread James Alton
Alternatively, output to a file, don't sleep (unless you really need to?), then tail that file in another console. (This would be for if you wanted to see different parts of the "printed" output while the program is still going.) James On Wed, Jun 5, 2013 at 5:18 AM, Neman

Re: how to make perl program run continue when i press control+s to pause screen output

2013-06-05 Thread James Alton
Beginner to beginner here, but if you wanted to do two things at once, wouldn't you just need to use threads? http://perldoc.perl.org/threads.html (Disclaimer: Threads might be overkill, but it was the first thing I thought of.) James On Wed, Jun 5, 2013 at 5:18 AM, Nemana, Satya wrote:

RE: Perl error codes and warnings

2013-05-29 Thread Warren James - jawarr
Shaji - Upon completion, is this something which you could please consider providing to us/the list audience as well?: "...a document with suitable code snippets which includes the most common Perl programming errors and warnings." THANKS JJW From: *Shaji Kalidasan* [mailto:shajiin...@yahoo.com

Re: Exposed Email Addresses

2013-03-29 Thread James Griffin
e why. Just set up a gmail account and have it forward messages to your server and then use the gmail address for mailing list communication. I personally just have OpenBSD spamd, spamassassin and blacklist stuff I don't want. It works well. Jamie. -- James Griffin: jmz at kontrol.kode5

Re: Problem Installing perlbrew [solved]

2013-03-21 Thread James Griffin
general that you've selected the "Login Shell" box so it runs bash as a login shell. -- James Griffin: jmz at kontrol.kode5.net jmzgriffin at gmail.com A4B9 E875 A18C 6E11 F46D B788 BEE6 1251 1D31 DC38 -- To unsubscribe, e-mail: beginners-unsubscr.

Re: .profile not being read

2013-02-20 Thread James Griffin
- Brian Fraser [2013-02-20 07:01:35 -0300] - : > On Tue, Feb 19, 2013 at 10:29 PM, Gerard Walschap wrote: > > I see. There is a .bashrc file in my home directory with the line > > - > > source /Users/gerard/perl5/perlbrew/etc/bashrc > > - > > So I guess in

Re: .profile not being read

2013-02-19 Thread James Griffin
- Gerard Walschap [2013-02-18 19:16:22 -0600] - : > Thanks to all. I guess I misunderstood the first post regarding > .bash.profile. Just to make sure I understand, are you saying I should try > replacing the .profile with .bash_profile? The shell is bash by default. > > -G

Cannot connect to Oracle db; script will not run

2012-07-31 Thread Warren James - jawarr
jjw_lookups.pl has failed due to ORACLE ERROR(S): \n\n It is $tempDate \n\n $tempORAError\" | mailx -s \"Moja Table Lookups Errors\" \" $global_email \" "); exit; } ~That produces this not very informative, error generated email: -Original Message

Testing for Missing Packages

2011-12-24 Thread Eric James Michael Ritz
Hello everyone. Here is my question: What is the preferred way to test a system for installed modules? For example, I have a Perl program I would like to distribute. It depends on a number of modules from CPAN and I would like an easy way to test for the existence of those modules. I suppose t

Re: perl script help

2011-10-13 Thread james varghese
u and now its working fine. Thanks again, James -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

perl script help

2011-10-11 Thread james varghese
hi, I am new to perl programming.I am trying with the following script and need help for it. I consolidated 10 excel files(in .txt format) which has same headers in it and so i made it 1 common header at the top.While doing it,in final output file i see a blank row at the beginning of every file c

Re: Short survey concerning the use of software engineering in the field of High Performance Computing

2010-08-31 Thread James Olin Oden
It would be helpful if you defined High Performance Computing. As far as I can tell that is just a marketing term with no technical basis. I would gladly believe otherwise if you would inform me. I ask this most respectfullyjames On Tue, Aug 31, 2010 at 9:20 AM, Markus Schmidberger wrote

Re: Modifying files with PERL

2009-12-15 Thread James Olin Oden
ded? I know what this script does, but I don't know what it is supposed to do...james -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Re: Closing all filehandles associated with a filedescriptor...

2009-12-12 Thread James Olin Oden
l provide a function that will return this table as a list of filehandles. It would be cool though if this already existed, but I'm not seeing it. Thanks...james -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Re: Closing all filehandles associated with a filedescriptor...

2009-12-11 Thread James Olin Oden
On Fri, Dec 11, 2009 at 4:36 PM, Shawn H Corey wrote: > James Olin Oden wrote: >> Hi All, >> >> This is really not a beginner question but I'm not sure what list to post it >> on. >> >> I've created a daemon library for easily building daem

Closing all filehandles associated with a filedescriptor...

2009-12-11 Thread James Olin Oden
something already in perlio.c to do this (-:). And of course pointing me to a more appropriate list is fine too. Thanks...james -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

CPAN not working for me

2009-04-11 Thread Clinton James
Hi I'm trying to use CPAN to install modules on a Linux box as but it always fails. I'm logged in as root. Help appreciated. cpan[1]> force install HTML::HTMLDoc CPAN: Storable loaded ok (v2.18) Going to read /root/.cpan/Metadata

Re: "Programming Perl" vs perldoc

2009-04-09 Thread James Coupe
free if you accept standard 2nd class delivery. 30.99 GBP in USD is *drumroll* $46. http://www.google.co.uk/search?hl=en&q=30.99+gbp+in+usd -- James Coupe -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Re: calling a program from a perl script and redirecting to output to a file

2009-02-19 Thread James Moser
s ;) David R. Wagner Senior Programmer Analyst FedEx Freight 1.719.484.2097 TEL 1.719.484.2419 FAX 1.408.623.5963 Cell http://fedex.com/us When using the system function I get an error. Does anyone know how to achieve that in perl. thanks in advance, Thomas Sincerely, James Moser ja...@endpoi

Re: free perl editor wanted

2009-02-17 Thread James Moser
codes. Thanks Sincerely, James Moser ja...@endpoint.com There are 10 kinds of people in the world. Those who understand binary, and those who do not. -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Re: env

2008-12-05 Thread James Moser
is not listed as a perl predefined variable, though you or someone else could certainly create and use a variable by that name. If you are seeing %ENV_VARS is a perl script, that is most likely what someone has done. Sincerely, James Moser [EMAIL PROTECTED] There are 10 kinds of people

Re: Conditional Operator

2008-12-05 Thread James Moser
set $title to $title1 if defined, otherwise to $title2 if defined and otherwise to $old_title. Oh sweet, I did not know that... thanks Jenda! Sincerely, James Moser [EMAIL PROTECTED] There are 10 kinds of people in the world. Those who understand binary, and those who do not. -BEGIN PGP

Re: Conditional Operator

2008-12-05 Thread James Moser
title = $image->title2; } else { $title = $image->oldtitle; } Wouldn't this work for what you are trying to do: my $title = $image->title1 || $image->title2 || $image->oldtitle; Sincerely, James Moser [EMAIL PROTECTED] T

Re: Reading Files across directories and subdirectories

2008-12-02 Thread James Moser
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Dec 2, 2008, at 11:51 AM, John W. Krahn wrote: James Moser wrote: On Dec 2, 2008, at 5:48 AM, Koti wrote: I have a directory named "X" which has many sub directories "Y","Z","W" and many files a

Re: Reading Files across directories and subdirectories

2008-12-02 Thread James Moser
} else { print $l2; print " It's a file!\n"; } } } print "Enter The Directory Path"; $dir = ; chomp($dir); directory($dir); This should work for what your trying to do, but I have

Re: cpan shell wrong

2008-10-14 Thread james . conerly
I had a similar problem. Check out the contents of your urllist. This is what mine looked like: cpan[1]> o conf urllist urllist 0 [] 1 [ftp://carroll.cac.psu.edu/pub/CPAN/] 2 [ftp://cpan-du.viaverio.com/pub/CPAN/] 3 [ftp://cpan-sj.viaverio.com/pub/CP

Re: Passing "class" objects to a function

2008-10-01 Thread James Coupe
n two different locations as somebody else's problem. Largely, you both have a point and, to some extent, it probably depends on taste and gut instinct. To close: Anyway. Isn't history fascinating? Especially postmodern history? As Heidi would say: 'Tsall good. Except when it sucks. -- James Coupe -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/

Re: Limiting Toke::Parser

2008-06-29 Thread Clinton JAmes
Thank you for the response Rob and I apologise for my lack of clarity. Thank you Gunnar the last line in your snippet is what I was looking for. Rgds CCJ __ Not happy with your email address?. Get the one you really want - million

Limiting Toke::Parser

2008-06-27 Thread Clinton JAmes
Hi I'm trying to use Toke::Parse and would appreciate some advice. My html is something like this   advise you to                           apples                           oranges                           pears                           Smartshopper is provided by the http://www.fat.g

better memory use than a v.large skinny HoA???

2007-10-03 Thread James
I have some code which creates a hash of arrays (HoA) then runs a 'while' loop, growing the HoA until x. So far the code works great but I have a data set I know will create a huge HoA and maybe eat up the memory. It's 'skinny' data in terms of lots of 'keys' => a few array values each. I'm h

2d array in sub

2007-09-04 Thread James
I'm writing a sub that take as input, references to a 2d array and a hash-of- arrays. The 2d array never changes but I operate on and return an updated hash-of-arrays. My issue is that I can get the sub working fine, iterating though the 2d array correctly until I put a return statement in. O

Re: regex for matching repeated strings

2007-06-13 Thread James
Thanks all, I have something working > $data =~ s/(.*\n)(?=\1)//g; Can anyone explain the (?=\1) bit? I get the search replace. J. -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/

regex for matching repeated strings

2007-06-12 Thread James
Is there a way of writing a regex to find 1 or more occurances of specific text string, and replace with a single occurance. e.g.: AI01 AI01 AI01 AI01 needs to be replaced with AI001 thus (m/(AI\d{6}\n)/) will find one occurance and capture as $1 (assuming delimiter se

Re: Command line vs. cron

2006-09-13 Thread James Marks
On Sep 13, 2006, at 3:50 PM, John W. Krahn wrote: James Marks wrote: If I've correctly interpreted your suggested changes, the script now reads: -- SCRIPT -- #!/usr/bin/perl use warnings; use strict; my $log_file = '/home/james/httpsd_mysqld.log';

Re: Command line vs. cron

2006-09-13 Thread James Marks
(snip) Here's the script: #!/usr/bin/perl use warnings; use strict; my $log_file = '/home/james/code/cron_code/httpsd_mysqld_log_file'; open FILE_OUT, ">> $log_file" or die "Cannot open log file: $!"; select FILE_OUT; (my $month, my $day, m

Re: Command line vs. cron

2006-09-13 Thread James Marks
ables. (If your program runs fine from the command line but not under cron, this is probably why.)" - Travis Thanks, Travis. I'll look into that to get a better understanding of the cron environment. James -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands,

Re: Command line vs. cron

2006-09-13 Thread James Marks
On Sep 13, 2006, at 12:29 AM, John W. Krahn wrote: #!/usr/bin/perl use warnings; use strict; my $log_file = '/home/james/code/cron_code/httpsd_mysqld_log_file'; open FILE_OUT, ">> $log_file" or die "Cannot open log file: $!"; select FILE_OUT; (my $mo

Re: Command line vs. cron

2006-09-12 Thread James Marks
On Sep 12, 2006, at 11:02 PM, Mumia W. wrote: On 09/12/2006 11:28 PM, James Marks wrote: Hi folks, I don't know if this is a Perl or UNIX problem and I'm hoping you can help me figure that out. I wrote a script that checks to see if the httpsd and mysqld processes are running on

Re: Command line vs. cron

2006-09-12 Thread James Marks
On Sep 12, 2006, at 10:28 PM, Owen Cook wrote: Here's the script: #!/usr/bin/perl use warnings; use strict; my $log_file = '/home/james/code/cron_code/httpsd_mysqld_log_file'; open FILE_OUT, ">> $log_file" or die "Cannot open log file: $!";

Re: Command line vs. cron

2006-09-12 Thread James Marks
On Sep 12, 2006, at 9:59 PM, Owen Cook wrote: Here's the script: #!/usr/bin/perl use warnings; use strict; my $log_file = '/home/james/code/cron_code/httpsd_mysqld_log_file'; open FILE_OUT, ">> $log_file" or die "Cannot open log file: $!";

Command line vs. cron

2006-09-12 Thread James Marks
2 21:10:20 httpsd 23 mysqld 33 script output to log when run from cron: 2006-08-12 21:11:05 httpsd 1 mysqld 1 Here's the cron entry: */15* * * * perl /home/james/code/cron_code/httpsd_mysqld_check.pl Here's the script: #!/usr/bin/perl use warni

Re: Can't count array in hash in array - correx

2006-08-09 Thread James Marks
On Aug 9, 2006, at 12:59 AM, Beginner wrote: Are you using this $subdirectory_count = $web_sites_directory_tree[$i]{subdirectory}; or this. my $subdirectory_count = @{$web_sites_directory_tree[$i]{subdirectory} }; print "SUB= $subdirectory_count\n"; Because the first outputs: SUB= array(

Re: Can't count array in hash in array - correx

2006-08-09 Thread James Marks
On Aug 9, 2006, at 12:33 AM, James Marks wrote: Down, near the bottom of this example code (marked), I'm trying to count the number of elements of an array which is the value of a key in a hash which is, itself, an element of an array. So far, I've been unsuccessful and I'

Re: Can't count array in hash in array

2006-08-09 Thread James Marks
On Aug 9, 2006, at 12:40 AM, Beginner wrote: On 9 Aug 2006 at 0:33, James Marks wrote: Ohh ohh. I think I know this (they'll flame me if I'm wrong). Is it? use strict; use warnings; my $no_dirs = @{ $web_sites_directory_tree[$i]{subdirectory} }; I tried that (includ

Can't count array in hash in array

2006-08-09 Thread James Marks
Down, near the bottom of this example code (marked), I'm trying to count the number of elements of an array which is the value of a key in a hash which is, itself, an element of an array. So far, I've been unsuccessful and I'm stumped as to what to try next. Help? my @web_sites_directory_tree

Re: Regex find and replace - delete line

2006-07-26 Thread James Turnbull
gt;> >> . . . shouldn't that be "ne" instead of "eq"? >> > > Yes, of course it should be "ne" . . . Thanks to all! The above solution worked perfectly. Regards James Turnbull - -- James Turnbull <[EMAIL PROTECTED]> - --- Author of

Regex find and replace - delete line

2006-07-23 Thread James Turnbull
y element and delete it rather than replace it with null (and then write it out to a file using Tie::File)? Thanks James Turnbull - -- James Turnbull <[EMAIL PROTECTED]> - --- Author of Pro Nagios 2.0 (http://www.amazon.com/gp/product/1590596099/) Hardening Linux (http://www.amazon.com/gp/prod

Re: Exec a script on one server that will exec other scripts on a different serv

2006-06-17 Thread James Turnbull
> then disconnect the client, and what for another connection. > Of course rather than write a custom script for this there are a number of tools - for example cfengine (http://www.cfengine.org/) - that could achieve this. Regards James Turnbull - -- James Turnbull <[EMAIL PROTECTED]&g

Re: Getting ip address

2006-06-12 Thread James Turnbull
0.0.1" and push @a,$1 foreach `ifconfig -a`; print "@a"' Pipe the output to mail or the like. Regards James Turnbull - -- James Turnbull <[EMAIL PROTECTED]> - --- Author of Pro Nagios 2.0 (http://www.amazon.com/gp/product/1590596099/) Hardening Linux (http://www.amazon

Re: filter email

2006-05-05 Thread James Turnbull
some library that would ease the development of this > program. Appreciate if anybody could point to me and hopefully give some > sample programs. Thanks in advance. Sorry for my english. > Have a look here: http://www.perl.com/lpt/a/2004/06/10/email.html Regards James Turnbull --

Re: Date difference.

2006-04-05 Thread James Turnbull
lent summary of most methods at http://perlmeme.org/faqs/datetime/comparing_dates.html. Regards James Turnbull -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>

Re: Automatically scheduling the execution of a sub-routine

2006-04-04 Thread James Turnbull
if I seem a little slow on the uptake. :) Many Thanks James Turnbull -- James Turnbull <[EMAIL PROTECTED]> --- Author of Pro Nagios 2.0 (http://www.amazon.com/gp/product/1590596099/) Hardening Linux (http://www.amazon.com/gp/product/159059/) --- PGP Key (http://pgp.mit.edu:11371/pk

Re: Automatically scheduling the execution of a sub-routine

2006-04-03 Thread James Turnbull
Mr. Shawn H. Corey wrote: First question: are you running under M$ Windows or UNIX? Unix - Linux or BSD generally Second question: does this periodic function relying on data of the main process? Yes - it uses a hash defined in the mainline. Regards James Turnbull -- To unsubscribe

Re: Automatically scheduling the execution of a sub-routine

2006-04-03 Thread James Turnbull
James Turnbull wrote: Hi Anyone know of a way to create a loop (or something similar) that automatically schedules the execution of a sub-routine periodically from within a program, for example execute check() every 600 seconds or the like? The program would be running as a daemon on the

Automatically scheduling the execution of a sub-routine

2006-04-03 Thread James Turnbull
Hi Anyone know of a way to create a loop (or something similar) that automatically schedules the execution of a sub-routine periodically from within a program, for example execute check() every 600 seconds or the like? The program would be running as a daemon on the host. Thanks James

Re: pseudohash

2006-02-11 Thread James Marks
On Feb 11, 2006, at 12:16 PM, Owen wrote: James Marks wrote: On Feb 11, 2006, at 12:04 AM, Owen Cook wrote: Maybe have a read of perlref, try http://perldoc.perl.org/perlref.html To my amusement, when I followed your suggestion, I got: -- Perl 5.8.6 documentation -- Home > Sea

Re: pseudohash

2006-02-11 Thread James Marks
documentation -- Home > Search results Search results No matches found for your query "pseudohash" :) James

Digest::MD5 issues

2005-12-27 Thread James Turnbull
subroutine &Digest::base::new called at (eval 59) line 4345. I've goggled this but I don't see any fixes for the problem. Thanks James Turnbull -- James Turnbull <[EMAIL PROTECTED]> --- Author of Hardening Linux from Apress (http://www.amazon.com/exec/obidos/tg/detail/-/159059

Help with unpack function - C struct to Perl

2005-12-01 Thread James Turnbull
or now. Anyone know what data type to use? Can anyone provide any hints about how I should do this? Thanks in advance James Turnbull -- James Turnbull <[EMAIL PROTECTED]> --- Author of Hardening Linux from Apress (http://www.amazon.com/exec/obidos/tg/detail/-/159059/) --- PGP Key (http

Re: Fw: Could [you] [please] tell me how to remove white spacees presentbetween delimiter[s]

2005-09-02 Thread James Taylor
#!/usr/bin/perl my $st1="'---'~^ '123PS01D'~^"; for(split(/\~\^/,$st1)) { $_ =~ s/\s//g; # Do something with your variable } Is that what you're asking? I'm unsure [EMAIL PROTECTED] wrote: '---'~^ '123PS01D'~^ here delimiter is ~^ '---'~^'123PS01D'~^ Do u see the d

Re: LIB path question

2005-03-07 Thread James W. Thompson, II
Is there any method to more permanently modify the include path? I didn't notice any environment variables, is it stored in the registry or does ActiveState's Perl distro pull in anysort of configuration file? On Tue, 8 Mar 2005 00:42:11 +0100, John Doe <[EMAIL PROTECTED]> wrot

LIB path question

2005-03-07 Thread James W. Thompson, II
How is the lib path set with ActiveState Perl? Can I just drop my custom *.pm files into the /site/lib or /lib folders under the ActiveState installation? -- James W. Thompson, II (New Orleans, LA) -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED

Re: Text file too large for Perl?

2005-03-07 Thread James Marks
file, hence my original question, "Why?" Thanks, James -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>

Re: Text file too large for Perl?

2005-03-06 Thread James marks
is related to the file size. Does this make sense? James -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>

Re: Text file too large for Perl?

2005-03-06 Thread James marks
The problem is most likely in your algorithm. Show us the code. (Oops. Replied only to Charles by accident. Reposting to the list:) Sorry. I was posting a part of the real code only to avoid posting an overly long string of code. The problem, it seemed to me, was more likely some other limita

Text file too large for Perl?

2005-03-06 Thread James marks
in new context\n"; } elsif ($line_count == o) { ... } If this isn't going to work, how do a parse a 21.5 meg text file? Thanks! James -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>

  1   2   3   4   5   6   7   8   9   10   >