[28446] in Perl-Users-Digest
Perl-Users Digest, Issue: 9810 Volume: 10
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Fri Oct 6 06:06:00 2006
Date: Fri, 6 Oct 2006 03:05:11 -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 Fri, 6 Oct 2006 Volume: 10 Number: 9810
Today's topics:
"too many arguments" passing hash reference to subrouti <de@spamfree.com>
Can perl test for .mp3 file? <itfred@cdw.com>
Re: Can perl test for .mp3 file? <john@castleamber.com>
Re: Can perl test for .mp3 file? <vilmos@soti.ca>
Re: Complex regular expression <someone@example.com>
Re: Complex regular expression <peace.is.our.profession@gmx.de>
Re: Complex regular expression <peace.is.our.profession@gmx.de>
Re: Complex regular expression <bart@nijlen.com>
Re: Complex regular expression <bart@nijlen.com>
Re: Complex regular expression <peace.is.our.profession@gmx.de>
Re: Complex regular expression <bart@nijlen.com>
Re: How to handle Windows file names under Linux? - SOL <some@body.com>
Re: How to handle Windows file names under Linux? - SOL <josef.moellers@fujitsu-siemens.com>
Re: How to handle Windows file names under Linux? - SOL <peace.is.our.profession@gmx.de>
Re: How to handle Windows file names under Linux? <some@body.com>
Re: How to handle Windows file names under Linux? <josef.moellers@fujitsu-siemens.com>
Re: How to start Internet Explorer from Perl Script? <betterdie@gmail.com>
Re: LWP and Unicode <dale.gerdemann@googlemail.com>
new CPAN modules on Fri Oct 6 2006 (Randal Schwartz)
Re: newbie cspan example question <peace.is.our.profession@gmx.de>
Re: newbie structure question <peace.is.our.profession@gmx.de>
Output of Concise <bol@adv.magwien.gv.at>
Passing parameter through SOAP::Lite niraj.kumar.ait@gmail.com
Posting Guidelines for comp.lang.perl.misc ($Revision: tadmc@augustmail.com
Digest Administrivia (Last modified: 6 Apr 01) (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: Fri, 06 Oct 2006 10:38:15 +0100
From: Dean <de@spamfree.com>
Subject: "too many arguments" passing hash reference to subroutine
Message-Id: <452623d4$0$8749$ed2619ec@ptn-nntp-reader02.plus.net>
Running the code below I see the error:
Too many arguments for main::print_rHoHoH at ./usenet.pl line 21, near
"$xml)"
#!/usr/bin/perl -w
use XML::Simple;
sub print_rHoHoH(){
$rHoHoH=$_[0];
for my $k1 ( sort keys %$rHoHoH ) {
print "$k1\n";
for my $k2 ( sort keys %{$rHoHoH->{ $k1 }} ) {
print "\t$k2\n";
for my $k3 ( sort keys %{$rHoHoH->{ $k1 }->{ $k2 }} ) {
print "\t\t$k3 => $rHoHoH->{ $k1 }->{ $k2 }->{ $k3 }\n";
}
}
}
}
$xml=XMLin($ARGV[0]);
print_rHoHoH($xml);
I don't understand why passing the reference to the hash in the call to the
subroutine causes the error.
If I change the last line to
do print_rHoHoH($xml);
it works, but with a warning about 'do' being deprecated.
Any insight would be much appreciated.
Thanks.
------------------------------
Date: Fri, 06 Oct 2006 00:52:46 -0400
From: Fred <itfred@cdw.com>
Subject: Can perl test for .mp3 file?
Message-Id: <1s2dnQh9-JiDfLjYnZ2dnUVZ_qOdnZ2d@giganews.com>
Is it possible to test if a file is an .mp3 file or not
in perl? I looked at the File:: modules, and also the
stat() function, but they don't seem to support it.
This is on a Linux system, so I could always call the
"file" command withing the script. I could also check
that the extension is .mp3, but thought there might be
a module or function to handle this. There's a perl
module for just about everything!
-Thank you
> file myfile.mp3
myfile.mp3: MPEG ADTS, layer III, v1, 128 kBits, 44.1 kHz, JntStereo
------------------------------
Date: 6 Oct 2006 05:42:07 GMT
From: John Bokma <john@castleamber.com>
Subject: Re: Can perl test for .mp3 file?
Message-Id: <Xns9854722F4844castleamber@130.133.1.4>
Fred <itfred@cdw.com> wrote:
> Is it possible to test if a file is an .mp3 file or not
> in perl?
So you want to know if the type of the file is mp3?
> I looked at the File:: modules, and also the
> stat() function, but they don't seem to support it.
> This is on a Linux system, so I could always call the
> "file" command withing the script. I could also check
> that the extension is .mp3, but thought there might be
> a module or function to handle this. There's a perl
> module for just about everything!
The magic keyword is magic:
<http://search.cpan.org/search?query=magic&mode=all>
File::Type
File::MimeInfo::Magic
--
John Experienced Perl programmer: http://castleamber.com/
Perl help, tutorials, and examples: http://johnbokma.com/perl/
------------------------------
Date: 05 Oct 2006 23:00:46 -0700
From: Vilmos Soti <vilmos@soti.ca>
Subject: Re: Can perl test for .mp3 file?
Message-Id: <lqejtm3rw1.fsf@vilmos.msmri.medicine.ubc.ca>
Fred <itfred@cdw.com> writes:
> Is it possible to test if a file is an .mp3 file or not
> in perl? I looked at the File:: modules, and also the
> stat() function, but they don't seem to support it.
> This is on a Linux system, so I could always call the
> "file" command withing the script. I could also check
> that the extension is .mp3, but thought there might be
> a module or function to handle this. There's a perl
> module for just about everything!
Look for the File::MMagic module.
Vilmos
------------------------------
Date: Fri, 06 Oct 2006 06:10:09 GMT
From: "John W. Krahn" <someone@example.com>
Subject: Re: Complex regular expression
Message-Id: <5rmVg.3524$H7.602@edtnps82>
jayanthigk2004@yahoo.com wrote:
> Is it possible to write a regular expression for this ?
>
> Pattern: 999-99-999
>
> Where 9 is any number from 0 to 9
>
> However the user need not enter ALL the digits and dashes as given in
> the format.
>
> Whatever numbers and dashes he had entered must match the above format,
> from left to right, for only the charcters he has entered.
>
> For example
> 9
> 99
> 999
> 999-
> 999-9
> 999-99
> 999-99-
> 999-99-9
> 999-99-99
> 999-99-999
>
> Any of the above should result in a match
>
> Next, he can also put * before or after or before and after any of the
> above combination
/\A\*?\d(?:\d(?:\d(?:-(?:\d(?:\d(?:-(?:\d(?:\d\d?)?)?)?)?)?)?)?)?\*?\z/
John
--
Perl isn't a toolbox, but a small machine shop where you can special-order
certain sorts of tools at low cost and in short order. -- Larry Wall
------------------------------
Date: Fri, 06 Oct 2006 10:25:27 +0200
From: Mirco Wahab <peace.is.our.profession@gmx.de>
Subject: Re: Complex regular expression
Message-Id: <eg5462$fcp$1@mlucom4.urz.uni-halle.de>
Thus spoke jayanthigk2004@yahoo.com (on 2006-10-06 03:54):
> Is it possible to write a regular expression for this ?
> Pattern: 999-99-999
> Where 9 is any number from 0 to 9
> However the user need not enter ALL the digits and dashes as given in
> the format.
> Whatever numbers and dashes he had entered must match the above format,
> from left to right, for only the charcters he has entered.
> For example
> 9
> 99
> 999
> 999-
> 999-9
> 999-99
> 999-99-
> 999-99-9
> 999-99-99
> 999-99-999
I'd go just straightforward and wouldn't
think of complex things here, just use
the obvious:
my $regxp=qr/(\d{1,3}[-]{0,1})
(\d{0,2}[-]{0,1})
(\d{0,3})
$/x;
and test it against the 'negative'
examples. If it won't work, one
could do another shot ;-)
Regards
Mirco
------------------------------
Date: Fri, 06 Oct 2006 10:32:34 +0200
From: Mirco Wahab <peace.is.our.profession@gmx.de>
Subject: Re: Complex regular expression
Message-Id: <eg54jd$fcp$4@mlucom4.urz.uni-halle.de>
Thus spoke Mirco Wahab (on 2006-10-06 10:25):
> I'd go just straightforward and wouldn't
> think of complex things here, just use
> the obvious:
>
> my $regxp=qr/(\d{1,3}[-]{0,1})
> (\d{0,2}[-]{0,1})
> (\d{0,3})
> $/x;
>
Oops, I forgot the '*stars*' thing, sorry ;-)
my $regexp=qr/^
[*]{0,1}
\d{1,3}[-]{0,1}
\d{0,2}[-]{0,1}
\d{0,3}
[*]{0,1}
$/x;
Regards,
Mirco
------------------------------
Date: 6 Oct 2006 01:42:26 -0700
From: "Bart Van der Donck" <bart@nijlen.com>
Subject: Re: Complex regular expression
Message-Id: <1160124146.370587.165900@i42g2000cwa.googlegroups.com>
John W. Krahn wrote:
> jayanthigk2004@yahoo.com wrote:
> > Is it possible to write a regular expression for this ?
> >
> > Pattern: 999-99-999
> >
> > Where 9 is any number from 0 to 9
> >
> > However the user need not enter ALL the digits and dashes as given in
> > the format.
> >
> > Whatever numbers and dashes he had entered must match the above format,
> > from left to right, for only the charcters he has entered.
> >
> > For example
> > 9
> > 99
> > 999
> > 999-
> > 999-9
> > 999-99
> > 999-99-
> > 999-99-9
> > 999-99-99
> > 999-99-999
> >
> > Any of the above should result in a match
> >
> > Next, he can also put * before or after or before and after any of the
> > above combination
>
>
> /\A\*?\d(?:\d(?:\d(?:-(?:\d(?:\d(?:-(?:\d(?:\d\d?)?)?)?)?)?)?)?)?\*?\z/
^\*?(\d{1,3}|\d{3}-(\d{0,2}|\d{2}-\d{0,3}))\*?$
--
Bart
------------------------------
Date: 6 Oct 2006 01:54:22 -0700
From: "Bart Van der Donck" <bart@nijlen.com>
Subject: Re: Complex regular expression
Message-Id: <1160124862.696058.26170@h48g2000cwc.googlegroups.com>
Mirco Wahab wrote:
> [...]
> my $regexp=qr/^
> [*]{0,1}
> \d{1,3}[-]{0,1}
> \d{0,2}[-]{0,1}
> \d{0,3}
> [*]{0,1}
> $/x;
No. That will incorrectly match things like
9-9
99-9999
9--
999--
99999
999999
--
Bart
------------------------------
Date: Fri, 06 Oct 2006 10:49:49 +0200
From: Mirco Wahab <peace.is.our.profession@gmx.de>
Subject: Re: Complex regular expression
Message-Id: <eg55jo$ft6$1@mlucom4.urz.uni-halle.de>
Thus spoke Bart Van der Donck (on 2006-10-06 10:42):
> John W. Krahn wrote:
>> jayanthigk2004@yahoo.com wrote:
>> > Pattern: 999-99-999
>>
>> /\A\*?\d(?:\d(?:\d(?:-(?:\d(?:\d(?:-(?:\d(?:\d\d?)?)?)?)?)?)?)?)?\*?\z/
>
> /^\*?(\d{1,3}|\d{3}-(\d{0,2}|\d{2}-\d{0,3}))\*?$/
>
/^\*?\d{1,3}-?\d{0,2}-?\d{0,3}\*?$/
Regards
M.
------------------------------
Date: 6 Oct 2006 02:04:10 -0700
From: "Bart Van der Donck" <bart@nijlen.com>
Subject: Re: Complex regular expression
Message-Id: <1160125450.401961.157350@b28g2000cwb.googlegroups.com>
Mirco Wahab wrote:
> /^\*?\d{1,3}-?\d{0,2}-?\d{0,3}\*?$/
Not correct. See my other reply to you in this thread.
--
Bart
------------------------------
Date: Fri, 06 Oct 2006 00:47:03 -0400
From: somebody <some@body.com>
Subject: Re: How to handle Windows file names under Linux? - SOLUTION
Message-Id: <xrGdnbxk0IlaQrjYnZ2dnUVZ_rKdnZ2d@giganews.com>
On Fri, 06 Oct 2006 01:56:49 +0200, Mirco Wahab wrote:
> This ain't \a li\nux file.mp3
> This is \file 1 & \file 2.mp3
>
> and compare with:
>
> my %f = ( q{This ain't \a li\nux file.mp3} => undef,
> q{This is \file 1 & \file 2.mp3} => undef );
>
> open( $f{$_}, '>', $_) || die "$_ $!" for keys %f;
> close $f{$_} for keys %f;
>
>
> $> ls -la
> ... This is \file 1 & \file 2.mp3
> ... This ain't \a li\nux file.mp3
>
>
> You could use single quotes '' but need
> then of course to escape the internal \'
> by backslash:
>
> 'This ain\'t a linux file.mp3'
>
> Regards
>
> Mirco
Thank you, I have it working now.
------------------------------
Date: Fri, 06 Oct 2006 09:27:47 +0200
From: Josef Moellers <josef.moellers@fujitsu-siemens.com>
Subject: Re: How to handle Windows file names under Linux? - SOLUTION
Message-Id: <eg50l5$cq2$1@nntp.fujitsu-siemens.com>
Mirco Wahab wrote:
> Thus spoke somebody (on 2006-10-06 01:37):
>=20
>>On Thu, 05 Oct 2006 19:11:11 -0400, somebody wrote:
>>
>>>I have a perl script that I need to pass some files to via
>>>the command line under Linux. The file names may contain
>>>single quotes and or ampersands like:
>>>This ain't a linux file.mp3
>>>This is file 1 & file 2.mp3
>>>
>>>How can I handle the above 2 file names in a perl
>>>script running under Linux? I haven't tried yet,
>>>but I don't believe simply enclosing them in single
>>>quotes or back tics 0will work like:
>>
>>So far, all I need to do is enclose the file name in
>>double quotes, and the perl script handles it without
>>any problems. I didn't think it would be that simple!
>=20
>=20
> This won't work if there are backslashes \ in your file,
> they will 'garble' your file name.
The OP was referring to "Windows _file_ names", not "Windows _path_=20
names"! If the name on Windows contained a backslash it would be a pathna=
me.
>=20
> Try:
>=20
> This ain't \a li\nux file.mp3
This\Is\A\Windows\Path.mp3
Josef
--=20
Josef M=F6llers (Pinguinpfleger bei FSC)
If failure had no penalty success would not be a prize
-- T. Pratchett
------------------------------
Date: Fri, 06 Oct 2006 09:51:51 +0200
From: Mirco Wahab <peace.is.our.profession@gmx.de>
Subject: Re: How to handle Windows file names under Linux? - SOLUTION
Message-Id: <eg5272$esc$1@mlucom4.urz.uni-halle.de>
Thus spoke Josef Moellers (on 2006-10-06 09:27):
> Mirco Wahab wrote:
>> Thus spoke somebody (on 2006-10-06 01:37):
>> This won't work if there are backslashes \ in your file,
>> they will 'garble' your file name.
>
> The OP was referring to "Windows _file_ names", not "Windows _path_
> names"! If the name on Windows contained a backslash it would be a pathname.
Lets see -- I didn't believe this first and
tried to write a 'abc\xyz.def' file to a
remote windows share mounted by samba.
It didn't work - so you are correct.
(I didn't think about that, thanks)
Regards
Mirco
------------------------------
Date: Fri, 06 Oct 2006 00:46:33 -0400
From: somebody <some@body.com>
Subject: Re: How to handle Windows file names under Linux?
Message-Id: <xrGdnb1k0Ik0QrjYnZ2dnUVZ_rKdnZ2d@giganews.com>
On Thu, 05 Oct 2006 23:52:38 +0000, John W. Krahn wrote:
>> 'This ain't a linux file.mp3'
>
> 'This ain\'t a linux file.mp3'
>
> q{This ain't a linux file.mp3}
>
> q!This ain't a linux file.mp3!
>
> etc., etc.
>
>
> John
Thanks.
------------------------------
Date: Fri, 06 Oct 2006 09:31:34 +0200
From: Josef Moellers <josef.moellers@fujitsu-siemens.com>
Subject: Re: How to handle Windows file names under Linux?
Message-Id: <eg50sa$dlm$1@nntp.fujitsu-siemens.com>
somebody wrote:
> I have a perl script that I need to pass some files to via
> the command line under Linux. The file names may contain
> single quotes and or ampersands like:
>=20
> This ain't a linux file.mp3
> This is file 1 & file 2.mp3
>=20
>=20
> How can I handle the above 2 file names in a perl
> script running under Linux? I haven't tried yet,
> but I don't believe simply enclosing them in single
> quotes or back tics 0will work like:
>=20
> 'This ain't a linux file.mp3'
If you quote the filename, you can use double quotes and escapes to=20
handle that, I sometimes pragmatically use the dot . If you have these=20
names in variables (e.g. because they are read in from a file or taken=20
from the command line), you don't have to worry.
--=20
Josef M=F6llers (Pinguinpfleger bei FSC)
If failure had no penalty success would not be a prize
-- T. Pratchett
------------------------------
Date: 6 Oct 2006 01:10:24 -0700
From: "paul" <betterdie@gmail.com>
Subject: Re: How to start Internet Explorer from Perl Script?
Message-Id: <1160122224.857425.39330@e3g2000cwe.googlegroups.com>
I am not quick sure about your question, but I guess it is
- For you to write Perl script to display on the IE
You need to configure your webserver and mare sure that your webserver
is understand your programm which is running, E.g CGI script
Using CGI script can make your life more easier..
Wish it could help
Paul
Mark Clements wrote:
> Paul Lalli wrote:
>
> >> b.. How to send key to surf web with same Internet Explorer?
> >
> > Not sure I understand your question. You want to write a Perl program
> > that will automatically manipulate an existing Internet Explorer
> > process? As in, you want to be able to send data to the process and
> > have it show up in IE's address bar or on a form? Why?
> >
> > Are you sure you don't just want to use WWW::Mechanize for automated
> > web browsing?
>
> As an addendum to this, if automating IE is, in fact, the requirement then
>
> Win32::IE::Mechanize
>
> is pretty handy. There is also Mozilla::Mechanize, but I have no
> experience with this.
>
>
>
> Mark
------------------------------
Date: 6 Oct 2006 01:55:21 -0700
From: "Dale" <dale.gerdemann@googlemail.com>
Subject: Re: LWP and Unicode
Message-Id: <1160124920.769047.228170@i42g2000cwa.googlegroups.com>
Mumia W. (reading news) wrote:
> 403 Forbidden
Whoops! I'm sure you managed to recreate the website yourself. But just
in case:
http://www.sfs.uni-tuebingen.de/~dg/fooo.html
The contents are:
%D1%86 a =D1=86
Sorry again for violating the newsgroup charter by using Unicode here.
But sometime there ought to be a discussion of why the newsgroup has
such a charter. Perl allows programs to be written with Unicode, but
such programs cannot be discussed here. Does this make sense?
------------------------------
Date: Fri, 6 Oct 2006 04:42:09 GMT
From: merlyn@stonehenge.com (Randal Schwartz)
Subject: new CPAN modules on Fri Oct 6 2006
Message-Id: <J6p6E9.1wr8@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.
Bot-Pastebot-0.50
http://search.cpan.org/~rcaputo/Bot-Pastebot-0.50/
----
CPAN-Test-Dummy-Perl5-Build-DepeFails-1.01
http://search.cpan.org/~andk/CPAN-Test-Dummy-Perl5-Build-DepeFails-1.01/
CPAN Test Dummy
----
CPAN-Test-Dummy-Perl5-Build-Fails-1.02
http://search.cpan.org/~andk/CPAN-Test-Dummy-Perl5-Build-Fails-1.02/
CPAN Test Dummy
----
CPAN-Test-Dummy-Perl5-Make-1.04
http://search.cpan.org/~andk/CPAN-Test-Dummy-Perl5-Make-1.04/
CPAN Test Dummy
----
CPANPLUS-0.075_01
http://search.cpan.org/~kane/CPANPLUS-0.075_01/
API & CLI access to the CPAN mirrors
----
CPANPLUS-Dist-PAR-0.02
http://search.cpan.org/~kane/CPANPLUS-Dist-PAR-0.02/
CPANPLUS distribution class to create PAR archives
----
DBD-DB2-0.9a
http://search.cpan.org/~ibmtordb2/DBD-DB2-0.9a/
DataBase Driver for DB2 UDB
----
DBD-DB2-0.9a-5.8.8
http://search.cpan.org/~ibmtordb2/DBD-DB2-0.9a-5.8.8/
DataBase Driver for DB2 UDB
----
DBIx-Class-0.07999_01
http://search.cpan.org/~blblack/DBIx-Class-0.07999_01/
Extensible and flexible object <-> relational mapper.
----
Email-Simple-1.992
http://search.cpan.org/~rjbs/Email-Simple-1.992/
Simple parsing of RFC2822 message format and headers
----
IO-Event-0.602
http://search.cpan.org/~muir/IO-Event-0.602/
Tied Filehandles for Nonblocking IO with Object Callbacks
----
IPC-Cmd-0.29_01
http://search.cpan.org/~kane/IPC-Cmd-0.29_01/
finding and running system commands made easy
----
Ingres-Utility-IIMonitor-0.12
http://search.cpan.org/~worm/Ingres-Utility-IIMonitor-0.12/
API to IIMONITOR Ingres RDBMS utility
----
Ingres-Utility-IINamu-0.03
http://search.cpan.org/~worm/Ingres-Utility-IINamu-0.03/
API to IINAMU Ingres RDBMS utility
----
Ingres-Utility-Netutil-0.02
http://search.cpan.org/~worm/Ingres-Utility-Netutil-0.02/
API to Netutil Ingres RDBMS utility
----
Konstrukt-0.5-beta4
http://search.cpan.org/~twittek/Konstrukt-0.5-beta4/
Web application/design framework
----
Konstrukt-0.5-beta5
http://search.cpan.org/~twittek/Konstrukt-0.5-beta5/
Web application/design framework
----
Konstrukt-0.5-beta6
http://search.cpan.org/~twittek/Konstrukt-0.5-beta6/
Web application/design framework
----
Lingua-Alphabet-Phonetic-0.051
http://search.cpan.org/~mthurn/Lingua-Alphabet-Phonetic-0.051/
map ABC's to phonetic alphabets
----
MP3-Icecast-Simple-0.2
http://search.cpan.org/~gregory/MP3-Icecast-Simple-0.2/
Simple MP3::Icecast wrapper
----
Mail-SpamAssassin-3.1.6
http://search.cpan.org/~dos/Mail-SpamAssassin-3.1.6/
Spam detector and markup engine
----
Module-CoreList-2.09
http://search.cpan.org/~rgarcia/Module-CoreList-2.09/
what modules shipped with versions of perl
----
Object-Accessor-0.32
http://search.cpan.org/~kane/Object-Accessor-0.32/
----
RPC-Object-0.02
http://search.cpan.org/~jwu/RPC-Object-0.02/
A lightweight implementation for remote procedure calls
----
RPC-Object-0.03
http://search.cpan.org/~jwu/RPC-Object-0.03/
A lightweight implementation for remote procedure calls
----
SAP-Rfc-1.53
http://search.cpan.org/~piers/SAP-Rfc-1.53/
SAP RFC - RFC Function calls against an SAP R/3 System
----
Test-Class-0.16
http://search.cpan.org/~adie/Test-Class-0.16/
Easily create test classes in an xUnit/JUnit style
----
Test-MockObject-1.07
http://search.cpan.org/~chromatic/Test-MockObject-1.07/
Perl extension for emulating troublesome interfaces
----
Test-Run-0.0100_10
http://search.cpan.org/~shlomif/Test-Run-0.0100_10/
----
Test-Run-CmdLine-0.0100_03
http://search.cpan.org/~shlomif/Test-Run-CmdLine-0.0100_03/
Analyze tests from the command line using Test::Run
----
Test-Run-Plugin-ColorSummary-0.0100_03
http://search.cpan.org/~shlomif/Test-Run-Plugin-ColorSummary-0.0100_03/
A Test::Run plugin that colors the summary.
----
Test-Run-Plugin-FailSummaryComponents-0.0100_02
http://search.cpan.org/~shlomif/Test-Run-Plugin-FailSummaryComponents-0.0100_02/
A Test::Run plugin that customizes the failure summary line.
----
Text-LooseCSV-1.5
http://search.cpan.org/~rsandberg/Text-LooseCSV-1.5/
Highly forgiving variable length record text parser; compare to MS Excel
----
WWW-Dict-Zdic-v0.0.1
http://search.cpan.org/~gugod/WWW-Dict-Zdic-v0.0.1/
Zdic Chinese Dictionary interface
----
Win32-Env-0.01
http://search.cpan.org/~rowaa/Win32-Env-0.01/
get and set global system and user enviroment varialbes under Win32.
----
WordNet-QueryData-1.42
http://search.cpan.org/~jrennie/WordNet-QueryData-1.42/
direct perl interface to WordNet database
----
forks-0.20
http://search.cpan.org/~rybskej/forks-0.20/
drop-in replacement for Perl threads using fork()
----
forks-BerkeleyDB-0.03
http://search.cpan.org/~rybskej/forks-BerkeleyDB-0.03/
high-performance drop-in replacement for threads
----
pcsc-perl-1.4.4
http://search.cpan.org/~whom/pcsc-perl-1.4.4/
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: Fri, 06 Oct 2006 09:47:15 +0200
From: Mirco Wahab <peace.is.our.profession@gmx.de>
Subject: Re: newbie cspan example question
Message-Id: <eg51ue$er3$1@mlucom4.urz.uni-halle.de>
Thus spoke ToddAndMargo@gbis.com (on 2006-10-06 02:02):
> I have been looking at:
> http://search.cpan.org/~ugansert/Paw-0.54/Paw/Popup.pm
>
> @butt=('Okay', 'Cancel');
> $text=('Do you really want to continue ?');
> $pu=Popup::new(height=>20, width=>20,
> buttons=>\@butt, text=>\$text);
>
> Having run the example and being told that something important
> was missing (Popup::new) I though I had better ask the following
> questions:
'paw' seems to be an old SuSE-related package
for drawing text shapes and stuff on top of
the unix 'curses' library. You need to have
that installed.
The 'paw'-documentation doesn't seem to help
much, its not longer maintained and I guess
nobody uses it much (could be wrong here).
The 'modules' you need, which are mostly
given in the 'paw'-examples, must be
installed before to your Perl-system
by the 'cpan' script.
$> cpan
will first brag about itself, ask
you some things and will allow you,
finally, to install things:
#[CPAN]> install Paw
the CPAN-programm will then try to load the
module from one of the internet archives
and install it on your computer. Do this
with all the modules you need.
Then you can use the Paw module and its
descendents by including it on top of
your script file:
-----[myfile.pl]----------
use Curses;
use Paw;
use Paw::Button;
use Paw::Box;
use Paw::Window;
...
# enter your Paw-related code here
The 'use' statements will load the
Paw-Modules (if you installed them before)
and the Rest of your program will know now
what to do if it stumbles upon:
...
@butt=('Okay', 'Cancel');
$text=('Do you really want to continue ?');
$pu=Popup::new(height=>20, width=>20,
buttons=>\@butt, text=>\$text);
...
In the end, it turns out the Perl-Module
System (CPAN) is one of the best
"Software-Block" providing systems
in existence.
Regards
Mirco
------------------------------
Date: Fri, 06 Oct 2006 09:34:14 +0200
From: Mirco Wahab <peace.is.our.profession@gmx.de>
Subject: Re: newbie structure question
Message-Id: <eg5161$ehh$1@mlucom4.urz.uni-halle.de>
Thus spoke ToddAndMargo@gbis.com (on 2006-10-06 01:49):
> My background is Modula2 and Bash scripts.
> ...
> 1) Under Modula2, best practice (or my practice) was from top
> to bottom
> a) make my declarations (which variable did what, etc.),
> b) write all my modules and functions, and
> c) in the body, place my code.
> Is this also the proper structure under Perl as well? (Think,
> this is your chance to influence me into good habits!)
You could do the same here, of course -
and express your intentions in the names
of variables and functions, as you like.
I don't think there can be a methodology
of creating software that fits for every
person and for every kind of program.
Mostly, I try to design 'front to back',
means, I'd try to figure out how I'd
like to have the interfaces to the
problem solving parts of the program
and put most effort in designing them.
But, it may depend ...
At the bottom line, you won't get around using:
- /packages/ (like 'objects') for the reusable stuff,
- /subroutines/ for splitting up the task into independent chunks,
- /data structures/ like arrays and hash maps for keeping the
model you work with,
- /variables/ of course to make things going,
... as in most other programming languages. You
can also map your style to most of the different
programming paradigms:
http://en.wikipedia.org/wiki/Programming_paradigm
without much problems, imho except some ;-)
What exactly did you do before?
Regards,
Mirco
------------------------------
Date: Fri, 6 Oct 2006 09:35:36 +0200
From: "Ferry Bolhar" <bol@adv.magwien.gv.at>
Subject: Output of Concise
Message-Id: <1160120137.690510@proxy.dienste.wien.at>
Hi,
when running code with
perl -MO=Concise,-exec
for lexical variables, I get output similar to this:
l <0> padsv[$Search:26,28]
What does the "26,28" mean?
And for concatenation,
12 <2> concat[t4] sK/2
What is the meaning of "[t4]"?
MTIA, and kind greetings,
Ferry
--
Ing Ferry Bolhar
Magistrat der Stadt Wien - MA 14
A-1010 Wien
E-Mail: bol@adv.magwien.gv.at
------------------------------
Date: 5 Oct 2006 23:16:39 -0700
From: niraj.kumar.ait@gmail.com
Subject: Passing parameter through SOAP::Lite
Message-Id: <1160115399.619934.134590@e3g2000cwe.googlegroups.com>
Hi,
How to pass parameter to method in SOAP::Lite. Like I want to set ABC
to xyz,CCNA to sdf
my $result = SOAP::Lite
->service('https://192.168.9.1/imaPreOrder/preOrder?WSDL')
->getCSR('ABC' => 'xyz',
'CCNA' => 'sdf',
);
I even tried SOAP :: Data
my $result = SOAP::Lite
->service('https://192.168.9.1/imaPreOrder/preOrder?WSDL')
->getCSR(SOAP::Data->name("ABC" => "xyz")
SOAP::Data->name("CCNA" => "I28"),
);
But these is not working .Please advice on how to pass data.
TIA
Niraj Kumar
------------------------------
Date: 06 Oct 2006 07:22:29 GMT
From: tadmc@augustmail.com
Subject: Posting Guidelines for comp.lang.perl.misc ($Revision: 1.6 $)
Message-Id: <45260435$0$47258$ae4e5890@news.nationwide.net>
Outline
Before posting to comp.lang.perl.misc
Must
- Check the Perl Frequently Asked Questions (FAQ)
- Check the other standard Perl docs (*.pod)
Really Really Should
- Lurk for a while before posting
- Search a Usenet archive
If You Like
- Check Other Resources
Posting to comp.lang.perl.misc
Is there a better place to ask your question?
- Question should be about Perl, not about the application area
How to participate (post) in the clpmisc community
- Carefully choose the contents of your Subject header
- Use an effective followup style
- Speak Perl rather than English, when possible
- Ask perl to help you
- Do not re-type Perl code
- Provide enough information
- Do not provide too much information
- Do not post binaries, HTML, or MIME
Social faux pas to avoid
- Asking a Frequently Asked Question
- Asking a question easily answered by a cursory doc search
- Asking for emailed answers
- Beware of saying "doesn't work"
- Sending a "stealth" Cc copy
Be extra cautious when you get upset
- Count to ten before composing a followup when you are upset
- Count to ten after composing and before posting when you are upset
-----------------------------------------------------------------
Posting Guidelines for comp.lang.perl.misc ($Revision: 1.6 $)
This newsgroup, commonly called clpmisc, is a technical newsgroup
intended to be used for discussion of Perl related issues (except job
postings), whether it be comments or questions.
As you would expect, clpmisc discussions are usually very technical in
nature and there are conventions for conduct in technical newsgroups
going somewhat beyond those in non-technical newsgroups.
The article at:
http://www.catb.org/~esr/faqs/smart-questions.html
describes how to get answers from technical people in general.
This article describes things that you should, and should not, do to
increase your chances of getting an answer to your Perl question. It is
available in POD, HTML and plain text formats at:
http://www.augustmail.com/~tadmc/clpmisc.shtml
For more information about netiquette in general, see the "Netiquette
Guidelines" at:
http://andrew2.andrew.cmu.edu/rfc/rfc1855.html
A note to newsgroup "regulars":
Do not use these guidelines as a "license to flame" or other
meanness. It is possible that a poster is unaware of things
discussed here. Give them the benefit of the doubt, and just
help them learn how to post, rather than assume
A note about technical terms used here:
In this document, we use words like "must" and "should" as
they're used in technical conversation (such as you will
encounter in this newsgroup). When we say that you *must* do
something, we mean that if you don't do that something, then
it's unlikely that you will benefit much from this group.
We're not bossing you around; we're making the point without
lots of words.
Do *NOT* send email to the maintainer of these guidelines. It will be
discarded unread. The guidelines belong to the newsgroup so all
discussion should appear in the newsgroup. I am just the secretary that
writes down the consensus of the group.
Before posting to comp.lang.perl.misc
Must
This section describes things that you *must* do before posting to
clpmisc, in order to maximize your chances of getting meaningful replies
to your inquiry and to avoid getting flamed for being lazy and trying to
have others do your work.
The perl distribution includes documentation that is copied to your hard
drive when you install perl. Also installed is a program for looking
things up in that (and other) documentation named 'perldoc'.
You should either find out where the docs got installed on your system,
or use perldoc to find them for you. Type "perldoc perldoc" to learn how
to use perldoc itself. Type "perldoc perl" to start reading Perl's
standard documentation.
Check the Perl Frequently Asked Questions (FAQ)
Checking the FAQ before posting is required in Big 8 newsgroups in
general, there is nothing clpmisc-specific about this requirement.
You are expected to do this in nearly all newsgroups.
You can use the "-q" switch with perldoc to do a word search of the
questions in the Perl FAQs.
Check the other standard Perl docs (*.pod)
The perl distribution comes with much more documentation than is
available for most other newsgroups, so in clpmisc you should also
see if you can find an answer in the other (non-FAQ) standard docs
before posting.
It is *not* required, or even expected, that you actually *read* all of
Perl's standard docs, only that you spend a few minutes searching them
before posting.
Try doing a word-search in the standard docs for some words/phrases
taken from your problem statement or from your very carefully worded
"Subject:" header.
Really Really Should
This section describes things that you *really should* do before posting
to clpmisc.
Lurk for a while before posting
This is very important and expected in all newsgroups. Lurking means
to monitor a newsgroup for a period to become familiar with local
customs. Each newsgroup has specific customs and rituals. Knowing
these before you participate will help avoid embarrassing social
situations. Consider yourself to be a foreigner at first!
Search a Usenet archive
There are tens of thousands of Perl programmers. It is very likely
that your question has already been asked (and answered). See if you
can find where it has already been answered.
One such searchable archive is:
http://groups.google.com/advanced_group_search
If You Like
This section describes things that you *can* do before posting to
clpmisc.
Check Other Resources
You may want to check in books or on web sites to see if you can
find the answer to your question.
But you need to consider the source of such information: there are a
lot of very poor Perl books and web sites, and several good ones
too, of course.
Posting to comp.lang.perl.misc
There can be 200 messages in clpmisc in a single day. Nobody is going to
read every article. They must decide somehow which articles they are
going to read, and which they will skip.
Your post is in competition with 199 other posts. You need to "win"
before a person who can help you will even read your question.
These sections describe how you can help keep your article from being
one of the "skipped" ones.
Is there a better place to ask your question?
Question should be about Perl, not about the application area
It can be difficult to separate out where your problem really is,
but you should make a conscious effort to post to the most
applicable newsgroup. That is, after all, where you are the most
likely to find the people who know how to answer your question.
Being able to "partition" a problem is an essential skill for
effectively troubleshooting programming problems. If you don't get
that right, you end up looking for answers in the wrong places.
It should be understood that you may not know that the root of your
problem is not Perl-related (the two most frequent ones are CGI and
Operating System related), so off-topic postings will happen from
time to time. Be gracious when someone helps you find a better place
to ask your question by pointing you to a more applicable newsgroup.
How to participate (post) in the clpmisc community
Carefully choose the contents of your Subject header
You have 40 precious characters of Subject to win out and be one of
the posts that gets read. Don't waste them. Take care while
composing them, they are the key that opens the door to getting an
answer.
Spend them indicating what aspect of Perl others will find if they
should decide to read your article.
Do not spend them indicating "experience level" (guru, newbie...).
Do not spend them pleading (please read, urgent, help!...).
Do not spend them on non-Subjects (Perl question, one-word
Subject...)
For more information on choosing a Subject see "Choosing Good
Subject Lines":
http://www.cpan.org/authors/id/D/DM/DMR/subjects.post
Part of the beauty of newsgroup dynamics, is that you can contribute
to the community with your very first post! If your choice of
Subject leads a fellow Perler to find the thread you are starting,
then even asking a question helps us all.
Use an effective followup style
When composing a followup, quote only enough text to establish the
context for the comments that you will add. Always indicate who
wrote the quoted material. Never quote an entire article. Never
quote a .signature (unless that is what you are commenting on).
Intersperse your comments *following* each section of quoted text to
which they relate. Unappreciated followup styles are referred to as
"top-posting", "Jeopardy" (because the answer comes before the
question), or "TOFU" (Text Over, Fullquote Under).
Reversing the chronology of the dialog makes it much harder to
understand (some folks won't even read it if written in that style).
For more information on quoting style, see:
http://web.presby.edu/~nnqadmin/nnq/nquote.html
Speak Perl rather than English, when possible
Perl is much more precise than natural language. Saying it in Perl
instead will avoid misunderstanding your question or problem.
Do not say: I have variable with "foo\tbar" in it.
Instead say: I have $var = "foo\tbar", or I have $var = 'foo\tbar',
or I have $var = <DATA> (and show the data line).
Ask perl to help you
You can ask perl itself to help you find common programming mistakes
by doing two things: enable warnings (perldoc warnings) and enable
"strict"ures (perldoc strict).
You should not bother the hundreds/thousands of readers of the
newsgroup without first seeing if a machine can help you find your
problem. It is demeaning to be asked to do the work of a machine. It
will annoy the readers of your article.
You can look up any of the messages that perl might issue to find
out what the message means and how to resolve the potential mistake
(perldoc perldiag). If you would like perl to look them up for you,
you can put "use diagnostics;" near the top of your program.
Do not re-type Perl code
Use copy/paste or your editor's "import" function rather than
attempting to type in your code. If you make a typo you will get
followups about your typos instead of about the question you are
trying to get answered.
Provide enough information
If you do the things in this item, you will have an Extremely Good
chance of getting people to try and help you with your problem!
These features are a really big bonus toward your question winning
out over all of the other posts that you are competing with.
First make a short (less than 20-30 lines) and *complete* program
that illustrates the problem you are having. People should be able
to run your program by copy/pasting the code from your article. (You
will find that doing this step very often reveals your problem
directly. Leading to an answer much more quickly and reliably than
posting to Usenet.)
Describe *precisely* the input to your program. Also provide example
input data for your program. If you need to show file input, use the
__DATA__ token (perldata.pod) to provide the file contents inside of
your Perl program.
Show the output (including the verbatim text of any messages) of
your program.
Describe how you want the output to be different from what you are
getting.
If you have no idea at all of how to code up your situation, be sure
to at least describe the 2 things that you *do* know: input and
desired output.
Do not provide too much information
Do not just post your entire program for debugging. Most especially
do not post someone *else's* entire program.
Do not post binaries, HTML, or MIME
clpmisc is a text only newsgroup. If you have images or binaries
that explain your question, put them in a publically accessible
place (like a Web server) and provide a pointer to that location. If
you include code, cut and paste it directly in the message body.
Don't attach anything to the message. Don't post vcards or HTML.
Many people (and even some Usenet servers) will automatically filter
out such messages. Many people will not be able to easily read your
post. Plain text is something everyone can read.
Social faux pas to avoid
The first two below are symptoms of lots of FAQ asking here in clpmisc.
It happens so often that folks will assume that it is happening yet
again. If you have looked but not found, or found but didn't understand
the docs, say so in your article.
Asking a Frequently Asked Question
It should be understood that you may have missed the applicable FAQ
when you checked, which is not a big deal. But if the Frequently
Asked Question is worded similar to your question, folks will assume
that you did not look at all. Don't become indignant at pointers to
the FAQ, particularly if it solves your problem.
Asking a question easily answered by a cursory doc search
If folks think you have not even tried the obvious step of reading
the docs applicable to your problem, they are likely to become
annoyed.
If you are flamed for not checking when you *did* check, then just
shrug it off (and take the answer that you got).
Asking for emailed answers
Emailed answers benefit one person. Posted answers benefit the
entire community. If folks can take the time to answer your
question, then you can take the time to go get the answer in the
same place where you asked the question.
It is OK to ask for a *copy* of the answer to be emailed, but many
will ignore such requests anyway. If you munge your address, you
should never expect (or ask) to get email in response to a Usenet
post.
Ask the question here, get the answer here (maybe).
Beware of saying "doesn't work"
This is a "red flag" phrase. If you find yourself writing that,
pause and see if you can't describe what is not working without
saying "doesn't work". That is, describe how it is not what you
want.
Sending a "stealth" Cc copy
A "stealth Cc" is when you both email and post a reply without
indicating *in the body* that you are doing so.
Be extra cautious when you get upset
Count to ten before composing a followup when you are upset
This is recommended in all Usenet newsgroups. Here in clpmisc, most
flaming sub-threads are not about any feature of Perl at all! They
are most often for what was seen as a breach of netiquette. If you
have lurked for a bit, then you will know what is expected and won't
make such posts in the first place.
But if you get upset, wait a while before writing your followup. I
recommend waiting at least 30 minutes.
Count to ten after composing and before posting when you are upset
After you have written your followup, wait *another* 30 minutes
before committing yourself by posting it. You cannot take it back
once it has been said.
AUTHOR
Tad McClellan <tadmc@augustmail.com> and many others on the
comp.lang.perl.misc newsgroup.
------------------------------
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 9810
***************************************