[28188] in Perl-Users-Digest
Perl-Users Digest, Issue: 9552 Volume: 10
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Thu Aug 3 03:05:52 2006
Date: Thu, 3 Aug 2006 00:05:08 -0700 (PDT)
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)
Perl-Users Digest Thu, 3 Aug 2006 Volume: 10 Number: 9552
Today's topics:
Beginner: match /$key/ <mstep@t-online.de>
Re: Beginner: match /$key/ <attn.steven.kuo@gmail.com>
Re: Beginner: match /$key/ <mstep@t-online.de>
Curl/Perl http post performanc issue <wkhedr@my-deja.com>
hash key and value <a@mail.com>
Re: hash key and value <betterdie@gmail.com>
Ideas for Plotting aircraft tracks in real-time <clydenospamorham@nospamorhamgetofftheline.freeservenospamorham.co.uk>
Re: Learning Typeglobs, Symbol Tables and the More Obsc <nospam-abuse@ilyaz.org>
Re: need perl dev in santa monica CA 100k+ f/t <dha@panix.com>
Re: need perl dev in santa monica CA 100k+ f/t usenet@DavidFilmer.com
Re: need perl dev in santa monica CA 100k+ f/t <David.Squire@no.spam.from.here.au>
Re: need perl dev in santa monica CA 100k+ f/t <dha@panix.com>
new CPAN modules on Thu Aug 3 2006 (Randal Schwartz)
opening file with parameters from perl script <Amaninder.Saini@gmail.com>
Re: opening file with parameters from perl script <1usa@llenroc.ude.invalid>
Re: perl + regex bug? <nospam-abuse@ilyaz.org>
Re: perl editor <bleatingedge@gmail.com>
perl linux serial example for non-blocking sonnichs@berkshire.net
Re: Perl/PHP Web Software Architects Needed <dha@panix.com>
Re: Problem starting a new thread from another thread tzhong98-101@yahoo.com
Re: Recursion <uri@stemsystems.com>
Digest Administrivia (Last modified: 6 Apr 01) (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: Thu, 03 Aug 2006 06:56:54 +0200
From: Marek Stepanek <mstep@t-online.de>
Subject: Beginner: match /$key/
Message-Id: <C0F74EB6.29757%mstep@t-online.de>
Thank you all, answering my questions in the thread "Beginner: regex-error?"
I appreciate your remarks, also if it is to early for me, to consider style
questions; I am lucky already, if my shell is spitting out some results ...
But I am reading and reading your answers, thinking: Wow! how elegant Perl
code may be by real professionals!
I am close to my original aim. I have two parts of data: first tab-delimited
numbers without dates. Second part tab-delimited text and numbers, starting
with a date. To the first part I add a date with the short name of the day
(in German) and I want to add to these lines the numbers at the end of the
second part, where the dates are the same AND where the line contains oU ...
(later I will calculate with these additional numbers, but this will be the
easy part - I hope!)
My idea was to read in all lines of the second part, containing oU, and
create a hash, where the date is the key, and see later where the keys
matches the lines of the first part.
The following script is working, but strange, only one $key (=date) is
matching, while there should be two!
Before you are suggesting a total other approach, could you help me to make
run this script here, with my idea? - I am sure there is a much more elegant
way to do this, but to learn, it is best for me to finish first one idea and
see later, how to achieve it professionally - the perlish way.
Thank you all, for your patience and the help!
marek
#!/usr/bin/perl
use warnings;
use strict;
use Date::Calc qw(:all);
my (@lines1, @lines2, @lines3);
my %date_number;
while (<DATA>)
{
chomp;
last if /keyword/;
push @lines1, $_;
}
chomp(@lines2=<DATA>);
my $start_day = "15";
my $start_month = "07";
my $year = "2006";
my $day = $start_day;
my $month = $start_month;
my ($wochentag, $date);
my %suplement;
foreach my $line (@lines1)
{
add_one_day();
push @lines3, "$wochentag, $date\t$line";
}
foreach my $line (@lines2)
{
if ($line =~ /oU/)
{
my ($datum) = $line =~ /^([\d.]+)\s/;
my ($number_to_add) = $line =~ /\s([\d.]+)\s*$/;
%suplement = ( $datum => $number_to_add );
}
}
foreach my $line (@lines3)
{
foreach my $key (keys %suplement)
{
if ( $line =~ /$key/)
{
$line .= "\t" . $suplement{$key};
print "the result of concatenation is: $line\n";
}
}
}
sub add_one_day
{
my $day_plus = 1;
my ($year2, $month2, $day2) = Add_Delta_Days($year, $month, $day,
$day_plus);
my $dow = Day_of_Week($year2,$month2,$day2);
Language(Decode_Language("Deutsch"));
my $lang = Language_to_Text(Language());
$wochentag = Day_of_Week_Abbreviation($dow);
$date = sprintf '%02d.%02d.%4d', $day2, $month2, $year2;
($day, $month, $year) = ($day2, $month2, $year2);
}
__DATA__
37086,4 15445 808 19,5 3156,3
37667 15769,2 817 19,5 3621
37936,5 15929,6 823 19,5 3857,8
38147,5 16058 827 19,5 4042,8
38371,8 16188,6 833 19,5 4247,4
38607,7 16252,7 837 19,5 4359,2
38752,7 16351,6 844 20,5 4523,9
38774,2 16351,6 844 20,5 4526,9
39056,9 16499,8 849 20,5 4740,6
39249,2 16574,6 853 20,5 4854,6
39720,7 16762,9 864 21,5 5148,7
39932 16847,6 872 22 5289,8
40002,6 16852,9 874 22 5307
keyword
17.07.2006 CC mU 58.00
17.07.2006 Fr. Knorr CC mU 60.00
18.07.2006 Unterföhring MUC Link CC mU 45.00
19.07.2006 CC mU 58.00
20.07.2006 MUC Hanauer Hermann/Wacki CC mU 55.00
21.07.2006 Claudio/Rock CC oU 55.00
24.07.2006 CC mU 54.00
24.07.2006 CC mU 50.00
24.07.2006 CC mU 55.00
25.07.2006 CC mU 82.00
26.07.2006 -3.7 Uhr! Königin MUC Wacki Bar oU 55.00
27.07.2006 hin rück Link CC mU 122.00
------------------------------
Date: 2 Aug 2006 22:42:53 -0700
From: "attn.steven.kuo@gmail.com" <attn.steven.kuo@gmail.com>
Subject: Re: Beginner: match /$key/
Message-Id: <1154583773.719294.45120@i3g2000cwc.googlegroups.com>
Marek Stepanek wrote:
(snipped)
>
> The following script is working, but strange, only one $key (=date) is
> matching, while there should be two!
>
> Before you are suggesting a total other approach, could you help me to make
> run this script here, with my idea? - I am sure there is a much more elegant
> way to do this, but to learn, it is best for me to finish first one idea and
> see later, how to achieve it professionally - the perlish way.
>
> Thank you all, for your patience and the help!
>
>
> marek
>
(snipped)
> foreach my $line (@lines2)
> {
> if ($line =~ /oU/)
> {
> my ($datum) = $line =~ /^([\d.]+)\s/;
> my ($number_to_add) = $line =~ /\s([\d.]+)\s*$/;
> %suplement = ( $datum => $number_to_add );
> }
> }
>
You're redefining the contents of the entire hash,
%suplement, instead of adding to it.
Read
%suplement = ( $datum => $number_to_add );
as:
The entire hash, %suplement, consists of a key-value
pair: the key being $datum, and the value being
$number_to add.
To add key-value pairs to the hash, use:
$suplement{ $datum } = $number_to_add;
--
Hope this helps,
Steven
------------------------------
Date: Thu, 03 Aug 2006 07:59:08 +0200
From: Marek Stepanek <mstep@t-online.de>
Subject: Re: Beginner: match /$key/
Message-Id: <C0F75D4C.2975C%mstep@t-online.de>
On 03.08.2006 07:42, in article
1154583773.719294.45120@i3g2000cwc.googlegroups.com,
"attn.steven.kuo@gmail.com" <attn.steven.kuo@gmail.com> wrote:
>
> To add key-value pairs to the hash, use:
>
> $suplement{ $datum } = $number_to_add;
Thank you Steven, I am blushing :-)
Greetings from Munich
------------------------------
Date: 2 Aug 2006 19:43:25 -0700
From: "wkhedr" <wkhedr@my-deja.com>
Subject: Curl/Perl http post performanc issue
Message-Id: <1154573005.138489.130380@i3g2000cwc.googlegroups.com>
We have a Perl program that has to do thousands of secure http post
requests to a web server as efficient as we could.
The web server sends back a big XML structure in every request.
We used Curl because it allowed us to deal with secured requests.
Curl by default uses http 1.1.
When we ask Curl to use http 1.0, we get average response time of 40
millisecond during our stress tests.
The response time is good but the problem is it's not releasing the
CPU's while waiting for the response. It's supposed to be like a disk
I/O where it should not be using the CPU. So the CPU utilization goes
up to 99% with multithreads of testing.
When we run the tests using http 1.1, the response time was 2 seconds
:)
Using http 1.1 and asking Curl to disable "Expect: 100-continue" by
using header "Expect:",
we were able to reach response time of 120 milliseconds and the CPU
usage was cut by almost 90%.
The question is: how can we get the best of the two settings: have the
same low CPU usage as http 1.1 and reduce the response time from 120 ms
to 40 ms as http 1.0?
Thanks
------------------------------
Date: Thu, 03 Aug 2006 04:26:48 GMT
From: "a" <a@mail.com>
Subject: hash key and value
Message-Id: <cWeAg.306192$iF6.92149@pd7tw2no>
Hi,
I have two hashes with the same set of keys but referring to 2 different
value sets.
I need to do the following:
foreach $key (@keys){
%hash1($key) / %hash2($key)
}
Is there any way to extract the value from the hash by the specified key?
Thanks
------------------------------
Date: 2 Aug 2006 22:36:13 -0700
From: "perlistpaul" <betterdie@gmail.com>
Subject: Re: hash key and value
Message-Id: <1154583373.675236.134970@i42g2000cwa.googlegroups.com>
You mean that you want to divid all the number in %hash1 with %hash2
my @results
foreach my $k(@keys) # foreach my $k(keys %hash1)
{
my $x=$hash1{$k}/$hash2{$k};
push(@results,$x);
}
--------------------------------------
a wrote:
> Hi,
> I have two hashes with the same set of keys but referring to 2 different
> value sets.
> I need to do the following:
> foreach $key (@keys){
> %hash1($key) / %hash2($key)
> }
> Is there any way to extract the value from the hash by the specified key?
> Thanks
------------------------------
Date: Thu, 03 Aug 2006 06:51:09 GMT
From: "Clyde Ingram" <clydenospamorham@nospamorhamgetofftheline.freeservenospamorham.co.uk>
Subject: Ideas for Plotting aircraft tracks in real-time
Message-Id: <x1hAg.17549$WY2.10066@newsfe3-gui.ntli.net>
I am building software to receive and handle aircraft track data (position,
altitude, course, speed, etc).
Just simulating a dozen aircraft, with the data for each aircraft updating a
couple of times per minute.
As an engineering tool (to prove that the software is making sense of the
data), and also 'cos it might look pretty cool, I'd like to display the
aircraft tracks on the screen, overlaid on a simple map. Each track will
appear as a small graphic, representing the aircraft type, pointing roughly
in the direction of travel, annotated with some brief notes on altitude and
speed. I know there are expensive, complex commercial packages out there
for such plotting. But I just hope to create a _simple_ proof-of-concept
demonstrator.
This is to run as a local application on a PC -- no need for web graphics.
Where do I start with the graphics display?
O'Reilly's "Perl Graphics Programming" (2002) hits we with a bewildering set
of graphics tools:
- GD
- Image::Magick
- Gimp
- SVG
- SWF
- Ming
Some of these seem to be specifically for the web.
What about Tk's Canvas widget? Or is that versatile enough?
From CPAN, the best match for the job looks like James Lee Carpenter's
Geo::GNUplot. So that's where I'll start.
Can anyone offer suggestions about tools to focus on or have experience of
this kind of thing?
I may re-post with concrete problems in due course.
Thank-you,
Clyde
------------------------------
Date: Thu, 3 Aug 2006 06:10:46 +0000 (UTC)
From: Ilya Zakharevich <nospam-abuse@ilyaz.org>
Subject: Re: Learning Typeglobs, Symbol Tables and the More Obscure Features?
Message-Id: <eas416$jag$1@agate.berkeley.edu>
[A complimentary Cc of this posting was sent to
<anno4000@radom.zrz.tu-berlin.de>], who wrote in article <4h29vaF1pav9iU1@news.dfncis.de>:
> > arrays and hashes, of course, plus formats, I think. But are directory
> > handles yet another kind of "scalar type"? I haven't found the answer in the
> > docs sofar.
> No, dir handles appear as a special case of file handle, both are
> accessed through (say) *main::HANDLE{ IO} as the case may be.
This is not so. Filehandles and dirhandles live in different
namespaces. (I have no idea what *HANDLE{IO} does if both exist.)
Witness
perl -wle "open F, shift or die; opendir F, '.' or die; while(1)
{print scalar <F>; print scalar readdir F}" readme*
(assuming readme* exists in the current directory).
Hope this helps (but probably it does not; this is another case of
heavy perl4 heritage),
Ilya
------------------------------
Date: Wed, 2 Aug 2006 22:06:26 +0000 (UTC)
From: "David H. Adler" <dha@panix.com>
Subject: Re: need perl dev in santa monica CA 100k+ f/t
Message-Id: <slrned28f3.6hi.dha@panix2.panix.com>
On 2006-08-02, usenet@DavidFilmer.com <usenet@DavidFilmer.com> wrote:
> usenet@DavidFilmer.com wrote:
>> I'm sure David Alder will be around shortly to further remind you...
>
> s/Alder/Adler/;
>
> Sorry about that, David.
Happens all the time. The weird thing is, although it happens all the
time, I have *never* come across anyone named Alder. :-)
dha
--
David H. Adler - <dha@panix.com> - http://www.panix.com/~dha/
So get it on paper, with a signature, so you can wave it at them. If
that doesn't work, use weapons.
- David Cantrell
------------------------------
Date: 2 Aug 2006 15:38:48 -0700
From: usenet@DavidFilmer.com
Subject: Re: need perl dev in santa monica CA 100k+ f/t
Message-Id: <1154558328.908600.61660@p79g2000cwp.googlegroups.com>
David H. Adler wrote:
> Happens all the time. The weird thing is, although it happens all the
> time, I have *never* come across anyone named Alder. :-)
Lots of towns have streets named Alder, including a somewhat
significant street through downtown Portland, OR (significant because
it becomes the eastbound lanes of the Morrison Bridge - all bridge
access points are significant in this West-coast City of Bridges).
Boy, how off-topic is THAT? I only mention it because I knew you were
here last week for OSCON, and you weren't very far from Alder St :-))
--
David Filmer (http://DavidFilmer.com)
------------------------------
Date: Wed, 02 Aug 2006 23:42:13 +0100
From: David Squire <David.Squire@no.spam.from.here.au>
Subject: Re: need perl dev in santa monica CA 100k+ f/t
Message-Id: <ear9o6$969$1@gemini.csx.cam.ac.uk>
usenet@DavidFilmer.com wrote:
> David H. Adler wrote:
>> Happens all the time. The weird thing is, although it happens all the
>> time, I have *never* come across anyone named Alder. :-)
>
> Lots of towns have streets named Alder,
Yep, but probably named after trees rather than people.
DS
------------------------------
Date: Thu, 3 Aug 2006 02:37:55 +0000 (UTC)
From: "David H. Adler" <dha@panix.com>
Subject: Re: need perl dev in santa monica CA 100k+ f/t
Message-Id: <slrned2oc4.983.dha@panix2.panix.com>
On 2006-08-02, David Squire <David.Squire@no.spam.from.here.au> wrote:
> usenet@DavidFilmer.com wrote:
>> David H. Adler wrote:
>>> Happens all the time. The weird thing is, although it happens all the
>>> time, I have *never* come across anyone named Alder. :-)
>>
>> Lots of towns have streets named Alder,
>
>
> Yep, but probably named after trees rather than people.
Exactly.
And, yes, I did notice Alder street in pdx last week. :-)
--
David H. Adler - <dha@panix.com> - http://www.panix.com/~dha/
Linguists don't know much, but they do know that nobody can succeed in
telling people at large how to speak. - Larry Wall
------------------------------
Date: Thu, 3 Aug 2006 04:42:08 GMT
From: merlyn@stonehenge.com (Randal Schwartz)
Subject: new CPAN modules on Thu Aug 3 2006
Message-Id: <J3Enq8.1yt1@zorch.sf-bay.org>
The following modules have recently been added to or updated in the
Comprehensive Perl Archive Network (CPAN). You can install them using the
instructions in the 'perlmodinstall' page included with your Perl
distribution.
Acme-MetaSyntactic-0.85
http://search.cpan.org/~book/Acme-MetaSyntactic-0.85/
Themed metasyntactic variables names
----
Acme-Terror-UK-0.01
http://search.cpan.org/~rprice/Acme-Terror-UK-0.01/
Fetch the current UK terror alert level
----
Apache-DBI-1.02
http://search.cpan.org/~pgollucci/Apache-DBI-1.02/
Initiate a persistent database connection
----
App-SimpleScan-Plugin-Forget-1.02
http://search.cpan.org/~mcmahon/App-SimpleScan-Plugin-Forget-1.02/
forget a variable's value
----
App-SimpleScan-Plugin-LinkCheck-1.02
http://search.cpan.org/~mcmahon/App-SimpleScan-Plugin-LinkCheck-1.02/
Link counting/presence/absence plugin
----
App-SimpleScan-Plugin-Plaintext-1.02
http://search.cpan.org/~mcmahon/App-SimpleScan-Plugin-Plaintext-1.02/
check a page's text without markup
----
App-SimpleScan-Plugin-Retry-1.02
http://search.cpan.org/~mcmahon/App-SimpleScan-Plugin-Retry-1.02/
implement retry pragma/command line option
----
AppConfig-1.63
http://search.cpan.org/~adamk/AppConfig-1.63/
Perl5 module for reading configuration files and parsing command line arguments.
----
Archive-Extract-0.11
http://search.cpan.org/~kane/Archive-Extract-0.11/
A generic archive extracting mechanism
----
Archive-Extract-0.11_01
http://search.cpan.org/~kane/Archive-Extract-0.11_01/
A generic archive extracting mechanism
----
Archive-Tar-1.30
http://search.cpan.org/~kane/Archive-Tar-1.30/
module for manipulations of tar archives
----
Array-AsHash-0.32
http://search.cpan.org/~ovid/Array-AsHash-0.32/
Treat arrays as a hashes, even if you need references for keys.
----
Bundle-Email-0.042
http://search.cpan.org/~rjbs/Bundle-Email-0.042/
a bundle to install the main set of Email:: modules
----
CPANPLUS-0.073_01
http://search.cpan.org/~kane/CPANPLUS-0.073_01/
API & CLI access to the CPAN mirrors
----
Data-Password-1.06
http://search.cpan.org/~razinf/Data-Password-1.06/
Perl extension for assesing password quality.
----
Data-SExpression-0.3
http://search.cpan.org/~nelhage/Data-SExpression-0.3/
Parse Lisp S-Expressions into perl data structures.
----
Date-Holidays-0.07
http://search.cpan.org/~jonasbn/Date-Holidays-0.07/
a Date::Holidays::* OOP wrapper
----
Devel-Pler-0.13
http://search.cpan.org/~adamk/Devel-Pler-0.13/
----
Email-FolderType-0.810
http://search.cpan.org/~rjbs/Email-FolderType-0.810/
determine the type of a mail folder
----
File-Fetch-0.08
http://search.cpan.org/~kane/File-Fetch-0.08/
A generic file fetching mechanism
----
GD-Graph-splined-0.02
http://search.cpan.org/~lgoddard/GD-Graph-splined-0.02/
Smooth line graphs with GD::Graph
----
GD-Graph-splined-1.16
http://search.cpan.org/~lgoddard/GD-Graph-splined-1.16/
Smooth line graphs with GD::Graph
----
GSSAPI-0.23
http://search.cpan.org/~agrolms/GSSAPI-0.23/
Perl extension providing access to the GSSAPIv2 library
----
Games-NES-ROM-0.02
http://search.cpan.org/~bricas/Games-NES-ROM-0.02/
View information about an NES game from a ROM file
----
IO-Socket-SSL-0.995
http://search.cpan.org/~sullr/IO-Socket-SSL-0.995/
Nearly transparent SSL encapsulation for IO::Socket::INET.
----
IO-Socket-SSL-0.996
http://search.cpan.org/~sullr/IO-Socket-SSL-0.996/
Nearly transparent SSL encapsulation for IO::Socket::INET.
----
IO-Socket-SSL-0.997
http://search.cpan.org/~sullr/IO-Socket-SSL-0.997/
Nearly transparent SSL encapsulation for IO::Socket::INET.
----
Inline-WSC-0.02
http://search.cpan.org/~johnd/Inline-WSC-0.02/
Use JavaScript and VBScript from within Perl
----
Log-Easy-0.01_11
http://search.cpan.org/~dirt/Log-Easy-0.01_11/
Easy to use, feature rich general purpose logging utility
----
Mail-LocalDelivery-0.301
http://search.cpan.org/~rjbs/Mail-LocalDelivery-0.301/
Deliver mail to a local mailbox
----
Net-Radius-1.46
http://search.cpan.org/~luismunoz/Net-Radius-1.46/
----
Net-TiVo-0.03
http://search.cpan.org/~boumenot/Net-TiVo-0.03/
Perl interface to TiVo.
----
NetAddr-IP-4.001
http://search.cpan.org/~luismunoz/NetAddr-IP-4.001/
Manages IPv4 and IPv6 addresses and subnets
----
PerlIO-via-CBC-0.08
http://search.cpan.org/~esskar/PerlIO-via-CBC-0.08/
PerlIO layer for reading/writing CBC encrypted files
----
RT-Client-REST-0.18
http://search.cpan.org/~dmitri/RT-Client-REST-0.18/
talk to RT installation using REST protocol.
----
RT-Client-REST-0.19
http://search.cpan.org/~dmitri/RT-Client-REST-0.19/
talk to RT installation using REST protocol.
----
RT-Client-REST-0.20
http://search.cpan.org/~dmitri/RT-Client-REST-0.20/
talk to RT installation using REST protocol.
----
Religion-Islam-PrayerTimes-1.02
http://search.cpan.org/~mewsoft/Religion-Islam-PrayerTimes-1.02/
Calculates Muslim Prayers Times and Sunrise
----
Religion-Islam-Qibla-1.01
http://search.cpan.org/~mewsoft/Religion-Islam-Qibla-1.01/
Calculates the Muslim Qiblah Direction, Great Circle Distance, and Great Circle Direction
----
Religion-Islam-Qibla-1.02
http://search.cpan.org/~mewsoft/Religion-Islam-Qibla-1.02/
Calculates the Muslim Qiblah Direction, Great Circle Distance, and Great Circle Direction
----
SQL-Loader-0.01
http://search.cpan.org/~benh/SQL-Loader-0.01/
----
SVN-Notify-2.63
http://search.cpan.org/~dwheeler/SVN-Notify-2.63/
Subversion activity notification
----
Sub-WrapPackages-1.2
http://search.cpan.org/~dcantrell/Sub-WrapPackages-1.2/
add pre- and post-execution wrappers around all the subroutines in packages or around individual subs
----
Task-Email-PEP-All-6213.124
http://search.cpan.org/~rjbs/Task-Email-PEP-All-6213.124/
every Perl Email Project distribution, for testing
----
Task-Email-PEP-All-6213.194
http://search.cpan.org/~rjbs/Task-Email-PEP-All-6213.194/
every Perl Email Project distribution, for testing
----
Task-Email-PEP-NoStore-6213.124
http://search.cpan.org/~rjbs/Task-Email-PEP-NoStore-6213.124/
every Perl Email Project distribution... except Email::Store
----
Task-Email-PEP-NoStore-6213.194
http://search.cpan.org/~rjbs/Task-Email-PEP-NoStore-6213.194/
every Perl Email Project distribution... except Email::Store
----
Text-TabFile-1.10
http://search.cpan.org/~bennie/Text-TabFile-1.10/
Module for parsing tab delimited files
----
Thread-Suspend-1.05
http://search.cpan.org/~jdhedden/Thread-Suspend-1.05/
Suspend and resume operations for threads
----
Tripletail-0.13
http://search.cpan.org/~mikage/Tripletail-0.13/
Tripletail, Framework for Japanese Web Application
----
WWW-TV-0.03
http://search.cpan.org/~tigris/WWW-TV-0.03/
Parse TV.com for information about TV shows.
----
XML-LibXML-1.59
http://search.cpan.org/~pajas/XML-LibXML-1.59/
Perl Binding for libxml2
----
XML-LibXSLT-1.59
http://search.cpan.org/~pajas/XML-LibXSLT-1.59/
Interface to the gnome libxslt library
If you're an author of one of these modules, please submit a detailed
announcement to comp.lang.perl.announce, and we'll pass it along.
This message was generated by a Perl program described in my Linux
Magazine column, which can be found on-line (along with more than
200 other freely available past column articles) at
http://www.stonehenge.com/merlyn/LinuxMag/col82.html
print "Just another Perl hacker," # the original
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
<merlyn@stonehenge.com> <URL:http://www.stonehenge.com/merlyn/>
Perl/Unix/security consulting, Technical writing, Comedy, etc. etc.
See PerlTraining.Stonehenge.com for onsite and open-enrollment Perl training!
------------------------------
Date: 2 Aug 2006 19:27:05 -0700
From: "Amaninder" <Amaninder.Saini@gmail.com>
Subject: opening file with parameters from perl script
Message-Id: <1154572025.497490.141380@s13g2000cwa.googlegroups.com>
HI everyone
I am able to open other files from my script using
system "start call \"inputs.pl\" ";
but i can not able to give parameters to inputs.pl, like
system "start call \"inputs.pl para1 para2 \" ";
input.pl file uses two parameters. If anyone did this before then let
me know the solution. Moreover, if someone knows how to open the
shortcut file, for example, "Shortcut to inputs.pl" then that would be
helpfull too.
Regards
Amaninder Saini :)
------------------------------
Date: Thu, 03 Aug 2006 02:57:50 GMT
From: "A. Sinan Unur" <1usa@llenroc.ude.invalid>
Subject: Re: opening file with parameters from perl script
Message-Id: <Xns9813E9B27C067asu1cornelledu@127.0.0.1>
"Amaninder" <Amaninder.Saini@gmail.com> wrote in
news:1154572025.497490.141380@s13g2000cwa.googlegroups.com:
> I am able to open other files from my script using
>
> system "start call \"inputs.pl\" ";
I suspect you are suffering from a serious misunderstanding. call is an
internal cmd.exe command for calling batch files.
Just type
C:\> call /?
to read about it.
I am assuming you know how start works, and you have determined it is
appropriate to use it in this case.
> but i can not able to give parameters to inputs.pl, like
>
> system "start call \"inputs.pl para1 para2 \" ";
D:\UseNet\clpmisc\pass> cat p.pl
#!/usr/bin/perl
use strict;
use warnings;
system qw(start q.pl arg1 arg2 arg3);
__END__
D:\UseNet\clpmisc\pass> cat q.pl
#!/usr/bin/perl
use strict;
use warnings;
print $_, "\n" for @ARGV;
sleep 10;
__END__
D:\UseNet\clpmisc\pass> p
<then, in a separate window>
arg1
arg2
arg3
Sinan
PS: You should read the posting guidelines for this group.
--
A. Sinan Unur <1usa@llenroc.ude.invalid>
(remove .invalid and reverse each component for email address)
comp.lang.perl.misc guidelines on the WWW:
http://augustmail.com/~tadmc/clpmisc/clpmisc_guidelines.html
------------------------------
Date: Thu, 3 Aug 2006 06:31:12 +0000 (UTC)
From: Ilya Zakharevich <nospam-abuse@ilyaz.org>
Subject: Re: perl + regex bug?
Message-Id: <eas57g$k3l$1@agate.berkeley.edu>
[A complimentary Cc of this posting was sent to
<nitroamos@gmail.com>], who wrote in article <1153513835.324982.209140@i42g2000cwa.googlegroups.com>:
> $index--; $index++;
>
> if($element =~ /_${index}_/ or $element =~ m/_$index$/){
> for some reason, without the $index--; $index++; business, my second
> pattern is not matching.
> Summary of my perl5 (revision 5.0 version 8 subversion 0)
> configuration:
So this is 5.8.0? Its REx engine is very buggy. For best results,
upgrade.
Hope this helps,
Ilya
------------------------------
Date: 2 Aug 2006 17:25:44 -0700
From: "bleatingedge" <bleatingedge@gmail.com>
Subject: Re: perl editor
Message-Id: <1154564744.261598.107740@75g2000cwc.googlegroups.com>
Abigail wrote:
>
> Hence my classification of 'toy distros'.
You walked right into that one, Michele... =0)
bleatingedge
--
perl -e '$a=shift;print pack("H".length $a,$a),"\n"' \
"687474703a2f2f7777772e6a757374616e6f7468657275726c70\
61636b65722e636f6d2f"
------------------------------
Date: 2 Aug 2006 20:31:46 -0700
From: sonnichs@berkshire.net
Subject: perl linux serial example for non-blocking
Message-Id: <1154575906.815361.129790@s13g2000cwa.googlegroups.com>
I have read the 8.10 faq for perl serial io and I am attempting to
convert some prior windows code to linux. This code does 2-way IO to
the serial port. It hangs after I write a command to the
serial-attached device. I would like to approach this problem first by
turning off blocking. The faq is rather vague here.
Can anyone point me of a text book or tutorial that explicitly
addresses the blocking issues for perl on linux AND SHOWS CODING
EXAMPLES. I am not adept at object perl and would prefer a non-object
vesion-
Thanks,
Fritz
------------------------------
Date: Wed, 2 Aug 2006 22:09:25 +0000 (UTC)
From: "David H. Adler" <dha@panix.com>
Subject: Re: Perl/PHP Web Software Architects Needed
Message-Id: <slrned28kl.6hi.dha@panix2.panix.com>
On 2006-08-02, rcopple <robertcopple123@gmail.com> wrote:
> PERL/PHP Web Software Architect
You have posted a job posting or a resume in a technical group.
Longstanding Usenet tradition dictates that such postings go into
groups with names that contain "jobs", like "misc.jobs.offered", not
technical discussion groups like the ones to which you posted.
Had you read and understood the Usenet user manual posted frequently to
"news.announce.newusers", you might have already known this. :) (If
n.a.n is quieter than it should be, the relevent FAQs are available at
http://www.faqs.org/faqs/by-newsgroup/news/news.announce.newusers.html)
Another good source of information on how Usenet functions is
news.newusers.questions (information from which is also available at
http://www.geocities.com/nnqweb/).
Please do not explain your posting by saying "but I saw other job
postings here". Just because one person jumps off a bridge, doesn't
mean everyone does. Those postings are also in error, and I've
probably already notified them as well.
If you have questions about this policy, take it up with the news
administrators in the newsgroup news.admin.misc.
http://jobs.perl.org may be of more use to you
Yours for a better usenet,
dha
--
David H. Adler - <dha@panix.com> - http://www.panix.com/~dha/
Looking at the cake is like looking at the future. Until you taste
it, what do you really know? And, of course, by then, it's much too
late. - Merlin, Excalibur
------------------------------
Date: 2 Aug 2006 20:15:14 -0700
From: tzhong98-101@yahoo.com
Subject: Re: Problem starting a new thread from another thread
Message-Id: <1154574914.185213.256140@b28g2000cwb.googlegroups.com>
I changed Thread to threads, and it works great. Thanks guys for your
help!
Tim
xhoster@gmail.com wrote:
> tzhong98-101@yahoo.com wrote:
> > I am trying to do some threading with perl, and my simple script just
> > refuses to work. Basically I created a new thread (T1), and then
> > attempted to create another one (T2) from within T1, which failed
> > silently. Could anyone tell me why that is?
>
> Do you get any message like this:
> A thread exited while 2 threads were running.
> If so, you should either join the threads or just put a sleep in the main
> code to give the threads time to finish.
>
> >
> > ======== The sample code ========
> >
> > #!C:/perl/bin/perl.exe
> >
> > use strict;
> > use IO::Socket;
> > use Thread;
>
> You should probably use threads;, not use Thread;.
>
> Xho
>
> --
> -------------------- http://NewsReader.Com/ --------------------
> Usenet Newsgroup Service $9.95/Month 30GB
------------------------------
Date: Wed, 02 Aug 2006 23:57:38 -0400
From: Uri Guttman <uri@stemsystems.com>
Subject: Re: Recursion
Message-Id: <x7slke79ot.fsf@mail.sysarch.com>
>>>>> "BE" == Bernard El-Hagin <bernard.el-haginDODGE_THIS@lido-tech.net> writes:
>> again, i suggest you read my sort paper and sort::maker's docs just
>> to learn some more about sorting.
BE> The way you plug your work at every single even remotely relevant
BE> opportunity is as tacky as you are arrogant.
if the module fits, i promote it. even modules i don't write.
BE> A long overdue *plonk*.
be seeing ya!
uri
--
Uri Guttman ------ uri@stemsystems.com -------- http://www.stemsystems.com
--Perl Consulting, Stem Development, Systems Architecture, Design and Coding-
Search or Offer Perl Jobs ---------------------------- http://jobs.perl.org
------------------------------
Date: 6 Apr 2001 21:33:47 GMT (Last modified)
From: Perl-Users-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin)
Subject: Digest Administrivia (Last modified: 6 Apr 01)
Message-Id: <null>
Administrivia:
#The Perl-Users Digest is a retransmission of the USENET newsgroup
#comp.lang.perl.misc. For subscription or unsubscription requests, send
#the single line:
#
# subscribe perl-users
#or:
# unsubscribe perl-users
#
#to almanac@ruby.oce.orst.edu.
NOTE: due to the current flood of worm email banging on ruby, the smtp
server on ruby has been shut off until further notice.
To submit articles to comp.lang.perl.announce, send your article to
clpa@perl.com.
#To request back copies (available for a week or so), send your request
#to almanac@ruby.oce.orst.edu with the command "send perl-users x.y",
#where x is the volume number and y is the issue number.
#For other requests pertaining to the digest, send mail to
#perl-users-request@ruby.oce.orst.edu. Do not waste your time or mine
#sending perl questions to the -request address, I don't have time to
#answer them even if I did know the answer.
------------------------------
End of Perl-Users Digest V10 Issue 9552
***************************************