[29240] in Perl-Users-Digest
Perl-Users Digest, Issue: 484 Volume: 11
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Tue Jun 5 11:10:04 2007
Date: Tue, 5 Jun 2007 08:09:09 -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 Tue, 5 Jun 2007 Volume: 11 Number: 484
Today's topics:
/e option in the s/// command sharma__r@hotmail.com
Re: /e option in the s/// command <mritty@gmail.com>
Auth DBI on apache <jcharth@gmail.com>
Re: Auth DBI on apache <noreply@gunnar.cc>
Re: contacting Alfred Reibenschuh, creator of (CPAN) PD <bugbear@trim_papermule.co.uk_trim>
Editor <tyjbxx@yahoo.com>
Re: Editor QoS@domain.invalid
Re: How do I get the data out of this array? <zen13097@zen.co.uk>
Re: How do I get the data out of this array? <mritty@gmail.com>
Re: How do I get the data out of this array? <gimme_this_gimme_that@yahoo.com>
Re: How to erase Hex value 0D from string? <tomica@vvv.xls>
Re: How to erase Hex value 13 from string? <sisyphus1@nomail.afraid.org>
Re: Need suggestions on a good locking module (Heinrich Mislik)
Negative times in Spreadsheet::WriteExcel? <josef.moellers@fujitsu-siemens.com>
Re: Negative times in Spreadsheet::WriteExcel? <mritty@gmail.com>
Re: Negative times in Spreadsheet::WriteExcel? <josef.moellers@fujitsu-siemens.com>
new CPAN modules on Tue Jun 5 2007 (Randal Schwartz)
Re: question about socket and scalar. <joe@inwap.com>
Re-entrant code ??? <tyjbxx@yahoo.com>
Re: Re-entrant code ??? <mritty@gmail.com>
Re: Spawning other processes but continue script <joe@inwap.com>
Re: Using foreach?? maybe.. <baxter.brad@gmail.com>
Win32::Perms and ACL order <Colin@Chaplin.me.uk>
Digest Administrivia (Last modified: 6 Apr 01) (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: Tue, 05 Jun 2007 03:34:07 -0700
From: sharma__r@hotmail.com
Subject: /e option in the s/// command
Message-Id: <1181039647.886078.33760@p77g2000hsh.googlegroups.com>
#############################
use strict;
use warnings;
my $var = "''''''''''''";
my $p_pulse = q{./\\};
my $n_pulse = q{'\\/};
my $knt = 1;
print $var;
$var =~ s/^((...){$knt}).../$1 . (($1 =~ m{'}) ? $n_pulse : $p_pulse)/
e; ## <---- offending line
print $var;
##########################
when I run the above piece of perl code i get the following warnings:
Use of uninitialized value in concatenation (.) or string at
line 12.
And when i change the $var to "..........." it works fine.
what could be the problem here?
TIA,
-rakesh
------------------------------
Date: Tue, 05 Jun 2007 10:46:28 -0000
From: Paul Lalli <mritty@gmail.com>
Subject: Re: /e option in the s/// command
Message-Id: <1181040388.759075.206800@h2g2000hsg.googlegroups.com>
On Jun 5, 6:34 am, sharma...@hotmail.com wrote:
> #############################
> use strict;
> use warnings;
>
> my $var = "''''''''''''";
>
> my $p_pulse = q{./\\};
> my $n_pulse = q{'\\/};
>
> my $knt = 1;
>
> print $var;
> $var =~ s/^((...){$knt}).../$1 . (($1 =~ m{'}) ? $n_pulse : $p_pulse)/
> e; ## <---- offending line
> print $var;
> ##########################
>
> when I run the above piece of perl code i get the following warnings:
> Use of uninitialized value in concatenation (.) or string at
> line 12.
> And when i change the $var to "..........." it works fine.
>
> what could be the problem here?
The $1, $2, $3 <etc> variables are set after every successful pattern
match. In your replacement, you are doing a pattern match. That
pattern match succeedes, because the current value of $1 does indeed
match m{'}. That successful match causes $1 to be set to undef,
because that pattern match doesn't have any capturing parentheses. So
it is the first $1 listed in your replacement - the one that's
concatenated to the result of the ?: operator - that's undefined.
It worked fine when you changed $var to all periods because then the
inner pattern match was not successful and so $1 wasn't changed.
You can fix this by saving off the value of $1 in your replacement, as
follows:
$var =~ s/^((...){$knt}).../my $save = $1; $save . (($save =~ m{'}) ?
$n_pulse : $p_pulse)/e;
Hope this helps,
Paul Lalli
------------------------------
Date: Tue, 05 Jun 2007 05:53:09 -0700
From: joe <jcharth@gmail.com>
Subject: Auth DBI on apache
Message-Id: <1181047989.408663.159950@h2g2000hsg.googlegroups.com>
Hello I am not sure if this is a perl question but i found a lot of
dbi apache results under perl. I got apache DBI enable on my
webserver, i would like to log successfull logins to a file or table.
is there an easy way to do this? thanks.
------------------------------
Date: Tue, 05 Jun 2007 15:13:16 +0200
From: Gunnar Hjalmarsson <noreply@gunnar.cc>
Subject: Re: Auth DBI on apache
Message-Id: <5cl60dF2voasnU1@mid.individual.net>
joe wrote:
> Hello I am not sure if this is a perl question but i found a lot of
> dbi apache results under perl. I got apache DBI enable on my
> webserver, i would like to log successfull logins to a file or table.
> is there an easy way to do this?
Please see http://dbi.perl.org/ about how to access a _database_,
including one of its tables, from Perl.
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
------------------------------
Date: Tue, 05 Jun 2007 13:13:48 +0100
From: bugbear <bugbear@trim_papermule.co.uk_trim>
Subject: Re: contacting Alfred Reibenschuh, creator of (CPAN) PDF-API2 ?
Message-Id: <4665537c$0$8727$ed2619ec@ptn-nntp-reader02.plus.net>
Sisyphus wrote:
>
>>
>
>
> For this particular module, I would be clicking on the "View/Report
> Bugs" link at:
> http://search.cpan.org/~areibens/PDF-API2-0.61/
> and then logging in using my PAUSE account.
>
> (I've never used a bitcard account. Perhaps there's a problem with
> bitcard accounts and rt.cpan.org, though I've not heard of any.)
OK. I finally got connected, and keyed in all my nice info.
Having clicked on "report bug" (I forget - the OK button)
I got a server 500 error.
I used my browser to go back (to the filled in form)
and tried a few times, separated by a few minutes.
I continued to get server errors.
Inevitably, of course, my email later reports I
now have 5 job tickets open for the same bug.
Aaargh!
So I go back to rt.cpan.org, and attempt to delete 4 of them
or at least status change them to "rejected" or something.
But the "modify" link for the bug:
http://rt.cpan.org/Ticket/Modify.html?id=27443
gets forwarded on to the home page:
http://rt.cpan.org/Public/
HELP!!!
BugBear
------------------------------
Date: Tue, 05 Jun 2007 06:05:20 -0700
From: tyjb <tyjbxx@yahoo.com>
Subject: Editor
Message-Id: <1181048720.607380.47180@g4g2000hsf.googlegroups.com>
I'd like to display the contents of a file to users giving them the
opportunity to search or scroll, but not allow them to change or
save. I can't use the "type" command because the files are too
large. Any suggestions?
This is what I'm currently doing, but need another method.
$myfile = $sortedarray[$input];
$mypath = '\\\\tlrntfs1\\IT_Common\\output\\';
$myprogram = '"C:\\Windows\\notepad.exe"';
$mycommand = $myprogram.' "'.$mypath.$myfile ;
system($mycommand);
------------------------------
Date: Tue, 05 Jun 2007 13:40:44 GMT
From: QoS@domain.invalid
Subject: Re: Editor
Message-Id: <wJd9i.6096$443.4943@trnddc05>
tyjb <tyjbxx@yahoo.com> wrote in message-id: <1181048720.607380.47180@g4g2000hsf.googlegroups.com>
>
>I'd like to display the contents of a file to users giving them the
>opportunity to search or scroll, but not allow them to change or
>save. I can't use the "type" command because the files are too
>large. Any suggestions?
>
>This is what I'm currently doing, but need another method.
>
>$myfile = $sortedarray[$input];
>$mypath = '\\\\tlrntfs1\\IT_Common\\output\\';
>$myprogram = '"C:\\Windows\\notepad.exe"';
>$mycommand = $myprogram.' "'.$mypath.$myfile ;
>system($mycommand);
You could try a Scrolled ROText widget from the Tk set of modules.
#/usr/bin/perl
use strict;
use warnings;
use Tk;
use Tk::ROText;
my($mw,);
$mw = MainWindow->new(-title => 'Tk ROText example');
&gui();
&Tk::MainLoop();
exit;
sub gui
{
my($txt1,);
$txt1 = $mw->Scrolled('ROText', -scrollbars => 'se',)->pack();
my $stuffToDisplay = "test\n"x50;
$txt1->insert('1.0', $stuffToDisplay);
}
------------------------------
Date: 05 Jun 2007 07:39:02 GMT
From: Dave Weaver <zen13097@zen.co.uk>
Subject: Re: How do I get the data out of this array?
Message-Id: <46651316$0$27851$db0fefd9@news.zen.co.uk>
gimme_this_gimme_that@yahoo.com <gimme_this_gimme_that@yahoo.com> wrote:
> In the Perl Debugger a variable $vc looks like this:
>
> DB<1> p $vc
> ARRAY(0x19d1f9c)
> DB<2> x $vc
> 0 ARRAY(0x19d1f9c)
> 0 ARRAY(0x19e0694)
> 0 2.0
> 1 3.0
> 1 ARRAY(0x19e064c)
> 0 7.0
> 1 6.0
> 2 ARRAY(0x19e067c)
> 0 8.0
> 1 12.0
>
> How to I get :
> 2 3
> 7 6
> 8 12
At a command prompt run
perldoc perlref
and learn all about references. That should give you the knowledge you
need to understand your data structure above.
To give you a clue:
print $vc->[0][0]
------------------------------
Date: Tue, 05 Jun 2007 10:51:53 -0000
From: Paul Lalli <mritty@gmail.com>
Subject: Re: How do I get the data out of this array?
Message-Id: <1181040713.891579.137820@g4g2000hsf.googlegroups.com>
On Jun 4, 11:11 pm, "gimme_this_gimme_t...@yahoo.com"
<gimme_this_gimme_t...@yahoo.com> wrote:
> In the Perl Debugger a variable $vc looks like this:
>
> DB<1> p $vc
> ARRAY(0x19d1f9c)
> DB<2> x $vc
> 0 ARRAY(0x19d1f9c)
> 0 ARRAY(0x19e0694)
> 0 2.0
> 1 3.0
> 1 ARRAY(0x19e064c)
> 0 7.0
> 1 6.0
> 2 ARRAY(0x19e067c)
> 0 8.0
> 1 12.0
This tells you that $vc is a reference to an array. The array that
$vc references contains three elements. Each of those elements are
also references to arrays. The arrays that *those* references
reference contain two elements each, all numbers.
Please see:
perldoc perlreftut
> How to I get :
> 2 3
> 7 6
> 8 12
Step by step:
$vc is a reference to an array
@{$vc} is the array that $vc references
${$vc}[0] is the first element of @{$vc}
The arrow rule lets us write that as $vc->[0]
$vc->[0] is also a reference to an array.
@{$vc->[0]} is the array that $vc->[0] references. This array
contains (2, 3);
So you could do a loop like the following:
foreach my $ref (@{$vc}) {
#here, $ref is one of the "inner" references
foreach my $elem (@{$ref}) {
print "$elem ";
}
print "\n";
}
Once you understand the above, you can make it much more concise:
foreach my $ref (@$vc) {
print "@{$ref}\n";
}
Hope this helps,
Paul Lalli
P.S. The final example presumes you've not mucked with the $"
variable.
------------------------------
Date: Tue, 05 Jun 2007 07:33:50 -0700
From: "gimme_this_gimme_that@yahoo.com" <gimme_this_gimme_that@yahoo.com>
Subject: Re: How do I get the data out of this array?
Message-Id: <1181054030.643844.158490@o11g2000prd.googlegroups.com>
Thanks Paul.
You're a pro.
------------------------------
Date: Tue, 5 Jun 2007 09:33:13 +0200
From: "Taomica" <tomica@vvv.xls>
Subject: Re: How to erase Hex value 0D from string?
Message-Id: <f433jn$pff$1@ss408.t-com.hr>
Thanks "It work!!!"
Super.
"Warren Block" <wblock@wonkity.com> wrote in message
news:slrnf68opo.9q7.wblock@speedy.wonkity.com...
> Taomica <tomica@vvv.xls> wrote:
>> Hex value is 0D, decimnal value is 13
>>
>>> How to erase Hex value 13 from string?
>>>
>>> Perl line : $b =~ tr/\013//;
>>> dont work?!
>
> \013 is octal. 0x0D = 13 = \015. Better to use \r if you mean carriage
> return, though. And as Gunnar said, you need the d modifier:
>
> $b =~ tr/\r//d;
>
> --
> Warren Block * Rapid City, South Dakota * USA
------------------------------
Date: Tue, 5 Jun 2007 19:44:22 +1000
From: "Sisyphus" <sisyphus1@nomail.afraid.org>
Subject: Re: How to erase Hex value 13 from string?
Message-Id: <46653071$0$29662$afc38c87@news.optusnet.com.au>
"Paul Lalli" <mritty@gmail.com> wrote in message
news:1180979670.729542.102720@q66g2000hsg.googlegroups.com...
> On Jun 4, 11:40 am, "Sisyphus" <sisyph...@nomail.afraid.org> wrote:
>
>> Untested:
>>
>> $b =~ s/chr(0x013)//;
>
> Function calls do not interpolate.
>
I must not reply to usenet posts while inebriated.
I must not reply to usenet posts while inebriated.
I must not reply to usenet posts while inebriated.
I must not reply to usenet posts while inebriated.
.
.
I must not reply to usenet posts while inebriated.
I must not reply to usenet posts while inebriated.
I must not reply to usenet posts while inebriated.
:-)
Cheers,
Rob
------------------------------
Date: 05 Jun 2007 08:23:27 GMT
From: Heinrich.Mislik@univie.ac.at (Heinrich Mislik)
Subject: Re: Need suggestions on a good locking module
Message-Id: <46651d7f$0$10578$3b214f66@usenet.univie.ac.at>
In article <MP6dndxNyasrifnbnZ2dnUVZ_v-tnZ2d@giganews.com>, ignoramus27175@NOSPAM.27175.invalid says...
>
>
>I have a script that I want to run, but only one instance. So I want
>to set up crontab to start it every minute, but if it is already
>running, I would exit.
>
>I looked at LockFile::Simple but I do not like it. I want to find a
>module that opens a file with O_EXCL and uses that for locking. (local
>hard drive filesystem only)
>
>I know that I could just use sysopen, but I am hoping that perhaps a
>well debugged module would clean some gotchas that I did not think
>about.
Look at Proc::PID::File
cheers
Heinrich
--
Heinrich Mislik
Zentraler Informatikdienst der Universitaet Wien
A-1010 Wien, Universitaetsstrasse 7
Tel.: (+43 1) 4277-14056, Fax: (+43 1) 4277-9140
------------------------------
Date: Tue, 05 Jun 2007 13:49:26 +0200
From: Josef Moellers <josef.moellers@fujitsu-siemens.com>
Subject: Negative times in Spreadsheet::WriteExcel?
Message-Id: <f43ikf$c7r$1@nntp.fujitsu-siemens.com>
Hi,
I'm trying to record time differences in an Excel spreadsheet, but I'm=20
unable to do this for negative differences:
use strict;
use warnings;
use Spreadsheet::WriteExcel;
my $workbook =3D Spreadsheet::WriteExcel->new('timediff.xls');
my $HHMM =3D $workbook->add_format(
font =3D> 'Arial',
size =3D> 10,
num_format =3D> 'hh:mm',
align =3D> 'center',
border =3D> 1,
);
my $worksheet =3D $workbook->add_worksheet('May');
my $diff =3D 10;
my $hhmm =3D sprintf('%02d', int($diff / 60))
. ':'
. sprintf('%02d', $diff % 60);
# The following is OK, prints "00:10"
$worksheet->write_date_time(0, 0, "T$hhmm", $HHMM);
# This prints "-T00:10"
$worksheet->write_date_time(1, 0, "-T$hhmm", $HHMM);
# This prints "T-00:10"
$worksheet->write_date_time(2, 0, "T-$hhmm", $HHMM);
$workbook->close();
--=20
These are my personal views and not those of Fujitsu Siemens Computers!
Josef M=F6llers (Pinguinpfleger bei FSC)
If failure had no penalty success would not be a prize (T. Pratchett)
Company Details: http://www.fujitsu-siemens.com/imprint.html
------------------------------
Date: Tue, 05 Jun 2007 05:23:37 -0700
From: Paul Lalli <mritty@gmail.com>
Subject: Re: Negative times in Spreadsheet::WriteExcel?
Message-Id: <1181046217.686215.230890@p77g2000hsh.googlegroups.com>
On Jun 5, 7:49 am, Josef Moellers <josef.moell...@fujitsu-siemens.com>
wrote:
> I'm trying to record time differences in an Excel spreadsheet, but I'm
> unable to do this for negative differences:
> # The following is OK, prints "00:10"
> $worksheet->write_date_time(0, 0, "T$hhmm", $HHMM);
> # This prints "-T00:10"
> $worksheet->write_date_time(1, 0, "-T$hhmm", $HHMM);
> # This prints "T-00:10"
> $worksheet->write_date_time(2, 0, "T-$hhmm", $HHMM);
I'm confused as to what you're going for. When I fire up Excel
itself, and try to enter a "negative" time (by either multiplying A1
from above by -1, or subtracting some value from it), I get a series
of "####" with a tooltip saying "negative dates or times are displayed
as ####".
If I understand correctly, you're hoping to display -70 minutes as
"-1:10", is that correct? I don't think Excel itself will do that.
This isn't a problem with Spreadsheet::WriteExcel...
Paul Lalli
------------------------------
Date: Tue, 05 Jun 2007 15:10:59 +0200
From: Josef Moellers <josef.moellers@fujitsu-siemens.com>
Subject: Re: Negative times in Spreadsheet::WriteExcel?
Message-Id: <f43ndh$tks$1@nntp.fujitsu-siemens.com>
Paul Lalli wrote:
> On Jun 5, 7:49 am, Josef Moellers <josef.moell...@fujitsu-siemens.com>
> wrote:
>=20
>>I'm trying to record time differences in an Excel spreadsheet, but I'm
>>unable to do this for negative differences:
>=20
>=20
>># The following is OK, prints "00:10"
>>$worksheet->write_date_time(0, 0, "T$hhmm", $HHMM);
>># This prints "-T00:10"
>>$worksheet->write_date_time(1, 0, "-T$hhmm", $HHMM);
>># This prints "T-00:10"
>>$worksheet->write_date_time(2, 0, "T-$hhmm", $HHMM);
>=20
>=20
> I'm confused as to what you're going for. When I fire up Excel
> itself, and try to enter a "negative" time (by either multiplying A1
> from above by -1, or subtracting some value from it), I get a series
> of "####" with a tooltip saying "negative dates or times are displayed
> as ####".
Somehow ist must be able to do that, as we're supposed to use an Excel=20
spreadsheet to record flexitime and it is perfectly capable of=20
displaying that I left 2 minutes too early as "-0:02".
When I take a look at the format of the cell, it says
Category: Custom
Type: [h]:mm;[Red]-[h]:mm
and the formula in one of these cells is
=3DIF(A15>0;IF(A15<=3DNOW();K15-L15;0);0)
> If I understand correctly, you're hoping to display -70 minutes as
> "-1:10", is that correct? I don't think Excel itself will do that.
> This isn't a problem with Spreadsheet::WriteExcel...
However, I'm unable to reproduce in an extremely simple sheet (A1=3D9:00,=
=20
B1=3D8:00, C1=3D"=3DB1-A1", format as shown above), so I guess this is so=
me=20
kind of Excel-wizardry and has nothing to do with Perl.
Thanks anyway for trying to help,
Josef
--=20
These are my personal views and not those of Fujitsu Siemens Computers!
Josef M=F6llers (Pinguinpfleger bei FSC)
If failure had no penalty success would not be a prize (T. Pratchett)
Company Details: http://www.fujitsu-siemens.com/imprint.html
------------------------------
Date: Tue, 5 Jun 2007 04:42:12 GMT
From: merlyn@stonehenge.com (Randal Schwartz)
Subject: new CPAN modules on Tue Jun 5 2007
Message-Id: <JJ5BqC.1C0n@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-Terror-NL-0.02
http://search.cpan.org/~blom/Acme-Terror-NL-0.02/
Fetch the current NL terror alert level
----
Apache2-ASP-0.17
http://search.cpan.org/~johnd/Apache2-ASP-0.17/
ASP for a mod_perl2 environment.
----
Archive-Zip-1.20
http://search.cpan.org/~adamk/Archive-Zip-1.20/
Provide an interface to ZIP archive files.
----
Catalyst-Plugin-C3-0.03
http://search.cpan.org/~blblack/Catalyst-Plugin-C3-0.03/
Catalyst Plugin to subvert NEXT to use Class::C3
----
Catalyst-Plugin-CRUD-0.19
http://search.cpan.org/~bayside/Catalyst-Plugin-CRUD-0.19/
CRUD (create/read/update/delete) Plugin for Catalyst
----
Class-C3-0.19
http://search.cpan.org/~blblack/Class-C3-0.19/
A pragma to use the C3 method resolution order algortihm
----
Class-C3-XS-0.07
http://search.cpan.org/~blblack/Class-C3-XS-0.07/
XS speedups for Class::C3
----
Class-Declare-0.08
http://search.cpan.org/~ibb/Class-Declare-0.08/
Declare classes with public, private and protected attributes and methods.
----
Class-Declare-Attributes-0.04
http://search.cpan.org/~ibb/Class-Declare-Attributes-0.04/
Class::Declare method types using Perl attributes.
----
File-EmptyDirs-1.02
http://search.cpan.org/~leocharre/File-EmptyDirs-1.02/
subs to help remove all empty dirs recursively
----
File-Filename-1.01
http://search.cpan.org/~leocharre/File-Filename-1.01/
expect a filename to be named by a person to be metadata
----
File-Find-Rule-DirectoryEmpty-1.01
http://search.cpan.org/~leocharre/File-Find-Rule-DirectoryEmpty-1.01/
test a directory for being empty
----
File-Find-Rule-DirectoryEmpty-1.09
http://search.cpan.org/~leocharre/File-Find-Rule-DirectoryEmpty-1.09/
test a directory for being empty
----
File-LocalizeNewlines-1.07
http://search.cpan.org/~adamk/File-LocalizeNewlines-1.07/
Localize the newlines for one or more files
----
Finance-QuoteOptions-0.11
http://search.cpan.org/~kbocek/Finance-QuoteOptions-0.11/
Perl extension for retrieving options pricing and series information from the web.
----
Gaim-Log-Parser-0.09
http://search.cpan.org/~mschilli/Gaim-Log-Parser-0.09/
Parse Gaim's Log Files
----
HTML-Table-2.06
http://search.cpan.org/~ajpeacock/HTML-Table-2.06/
produces HTML tables
----
IP-QQWry-v0.0.15
http://search.cpan.org/~sunnavy/IP-QQWry-v0.0.15/
a simple interface for QQWry IP database(file).
----
InSilicoSpectro-Databanks-0.0.19
http://search.cpan.org/~alexmass/InSilicoSpectro-Databanks-0.0.19/
parsing protein/nucleotides sequence databanks (fasta, uniprot...)
----
Lemonldap-Handlers-Generic-3.4.0
http://search.cpan.org/~egerman/Lemonldap-Handlers-Generic-3.4.0/
Perl extension for Lemonldap sso system
----
Lingua-EN-Words2Nums-0.15
http://search.cpan.org/~joey/Lingua-EN-Words2Nums-0.15/
convert English text to numbers
----
Log-Report-0.04
http://search.cpan.org/~markov/Log-Report-0.04/
report a problem, pluggable handlers and language support
----
MDV-Packdrakeng-1.11
http://search.cpan.org/~nanardon/MDV-Packdrakeng-1.11/
Simple Archive Extractor/Builder
----
MRO-Compat-0.03
http://search.cpan.org/~blblack/MRO-Compat-0.03/
mro::* interface compatibility for Perls < 5.9.5
----
Regexp-Assemble-0.31
http://search.cpan.org/~dland/Regexp-Assemble-0.31/
Assemble multiple Regular Expressions into a single RE
----
Sepia-0.90_02
http://search.cpan.org/~seano/Sepia-0.90_02/
Simple Emacs-Perl Interface
----
ShiftJIS-CP932-MapUTF-1.02
http://search.cpan.org/~sadahiro/ShiftJIS-CP932-MapUTF-1.02/
transcode between Microsoft CP932 and Unicode
----
ShiftJIS-X0213-MapUTF-0.31
http://search.cpan.org/~sadahiro/ShiftJIS-X0213-MapUTF-0.31/
conversion between Shift_JIS-2004/Shift_JISX0213 and Unicode
----
Sort-Key-Radix-0.05
http://search.cpan.org/~salva/Sort-Key-Radix-0.05/
Radix sort implementation in XS
----
Sort-Key-Radix-0.06
http://search.cpan.org/~salva/Sort-Key-Radix-0.06/
Radix sort implementation in XS
----
Sort-Key-Radix-0.07
http://search.cpan.org/~salva/Sort-Key-Radix-0.07/
Radix sort implementation in XS
----
Sort-Key-Radix-0.08
http://search.cpan.org/~salva/Sort-Key-Radix-0.08/
Radix sort implementation in XS
----
Sort-Key-Radix-0.09
http://search.cpan.org/~salva/Sort-Key-Radix-0.09/
Radix sort implementation in XS
----
TDB_File-0.95
http://search.cpan.org/~anguslees/TDB_File-0.95/
Perl access to the trivial database library
----
TDB_File-0.96
http://search.cpan.org/~anguslees/TDB_File-0.96/
Perl access to the trivial database library
----
Tie-Alias-1.00
http://search.cpan.org/~davidnico/Tie-Alias-1.00/
create aliases in pure perl
----
Tie-Alias-1.01
http://search.cpan.org/~davidnico/Tie-Alias-1.01/
create aliases in pure perl
----
Tree-Suffix-0.16
http://search.cpan.org/~gray/Tree-Suffix-0.16/
Perl interface to the libstree library.
----
WWW-Facebook-API-v0.3.2
http://search.cpan.org/~unobe/WWW-Facebook-API-v0.3.2/
Facebook API implementation
----
WWW-Myspace-0.64
http://search.cpan.org/~grantg/WWW-Myspace-0.64/
Access MySpace.com profile information from Perl
----
WebService-Lucene-0.04
http://search.cpan.org/~bricas/WebService-Lucene-0.04/
Module to interface with the Lucene indexing webservice
----
YAML-Tiny-1.10
http://search.cpan.org/~adamk/YAML-Tiny-1.10/
Read/Write YAML files with as little code as possible
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: Tue, 05 Jun 2007 01:00:08 -0700
From: Joe Smith <joe@inwap.com>
Subject: Re: question about socket and scalar.
Message-Id: <apednZ0xCKSUhfjbnZ2dnUVZ_h6vnZ2d@comcast.com>
_mario.lat wrote:
> socket(Socket_Handle, $family, $socktype, $proto) || next;
> connect(Socket_Handle, $saddr) && last;
>
> -----> WHAT CAN I PUT HERE TO PRINT WHAT SERVER SAYS?
It depends on whether the server is sending ordinary lines of text or
binary data. For binary, you'll need to worry about is the end-of-field,
end-of-record/packet and end-of-stream indicators, as well as the expected
maximum size of a packet.
-Joe
------------------------------
Date: Tue, 05 Jun 2007 05:58:39 -0700
From: tyjb <tyjbxx@yahoo.com>
Subject: Re-entrant code ???
Message-Id: <1181048319.355822.304380@p47g2000hsd.googlegroups.com>
I'm new to Windows perl and am recreating a menuing system that we
have on Unix, perl calling perl using the do command. The menus
present options to users with some options going to other menus. When
I execute one of the options, not another menu, I use "return" to
return to the calling menu/program. When I do, all numeric inputs
from the user are ignored. The only valid input is an "e" which exits
the menu. Any idea what's happening? Below is the code that returns
the program to the calling program.
if ($length == 0) {
print "Job $job currently has no output to display\n";
sleep 3;
return; }
------------------------------
Date: Tue, 05 Jun 2007 08:07:26 -0700
From: Paul Lalli <mritty@gmail.com>
Subject: Re: Re-entrant code ???
Message-Id: <1181056046.913356.249350@p47g2000hsd.googlegroups.com>
On Jun 5, 8:58 am, tyjb <tyj...@yahoo.com> wrote:
> I'm new to Windows perl and am recreating a menuing system that we
> have on Unix, perl calling perl using the do command. The menus
> present options to users with some options going to other menus. When
> I execute one of the options, not another menu, I use "return" to
> return to the calling menu/program. When I do, all numeric inputs
> from the user are ignored. The only valid input is an "e" which exits
> the menu. Any idea what's happening? Below is the code that returns
> the program to the calling program.
>
> if ($length == 0) {
> print "Job $job currently has no output to display\n";
> sleep 3;
> return; }
Please post a short BUT COMPLETE program that demonstrates what the
heck you're talking about.
This and other good advice can be found in the Posting Guidelines for
this group, posted here twice weekly.
Paul Lalli
------------------------------
Date: Tue, 05 Jun 2007 01:25:22 -0700
From: Joe Smith <joe@inwap.com>
Subject: Re: Spawning other processes but continue script
Message-Id: <XYGdnZA3XZxlgPjbnZ2dnUVZ_jednZ2d@comcast.com>
SimonH wrote:
> print `notepad`;
Why do you want to print 0? That is, why are backticks (``) being used?
It looks like the author does not know the difference between
$captured_output_from_program = `notepad`;
and
$error_code_exit_status = system 'notepad';
C:\> perldoc -q "output of a command"
-Joe
------------------------------
Date: Tue, 05 Jun 2007 14:04:40 -0000
From: Brad Baxter <baxter.brad@gmail.com>
Subject: Re: Using foreach?? maybe..
Message-Id: <1181052280.291592.181250@n4g2000hsb.googlegroups.com>
On Jun 3, 2:10 pm, Bob Walton <see....@rochester.rr.com> wrote:
> SimonH wrote:
> > The format of the machine.txt file is:
>
> > dell101
> > dell102
> > dell103
> > etc
>
> Try something like:
>
> use warnings;
> use strict;
> my $fh;
> my @computers;
> open $fh,"<","machine.txt"
> or die "Oops, couldn't open machine.txt for input, $!";
> while(<$fh>){
> chomp;
> push @computers,$_;
> }
> close($fh);
> #...
>
> ...> # Computer list
> > my @computers = qw/dell101 dell102 dell103/; # having trouble
> > here....instead of listing, id like to reference a file called machine.txt
Or a little more succinctly,
open my $fh,"<","machine.txt"
or die "Oops, couldn't open machine.txt for input, $!";
my @computers = <$fh>;
chomp @computers;
close($fh);
However, that slurps the whole file, which it looks like
you don't need. Instead, you could:
open my $fh,"<","machine.txt"
or die "Oops, couldn't open machine.txt for input, $!";
while( defined( my $computer = <$fh> ) ) {
chomp $computer;
# do all your other stuff with $computer
}
close($fh);
# or more succinctly ...
open $fh,"<","machine.txt"
or die "Oops, couldn't open machine.txt for input, $!";
while( <$fh> ) {
chomp;
# do all your other stuff with $_
}
close($fh);
And please improve your indentation. :-)
--
Brad
------------------------------
Date: Tue, 5 Jun 2007 12:44:49 +0100
From: "Colin Chaplin" <Colin@Chaplin.me.uk>
Subject: Win32::Perms and ACL order
Message-Id: <f43ibh$sto$1$8300dec7@news.demon.co.uk>
I've written a little program that adds permissions to files, making use of
win32::perms, and it's working quite well.
The only problem I have is that when I view the security tab under windows,
I get an error message about "The permissions on filename are incorrectly
ordered, which may cause some entries ..."
I gather this is because there is a set order for DACLS an I'm guessing the
win32::perms is just lumping my new DACL at the end.
Question is, how to fix it. My first attempt (wipe all ACLS, then apply a
new, ordered list) failed because (I think) after I've wiped the URLS there
are no longer any permissions do anything to the file.
I'm a little stuck here. Anyone got any ideas?
------------------------------
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 V11 Issue 484
**************************************