[30662] in Perl-Users-Digest

home help back first fref pref prev next nref lref last post

Perl-Users Digest, Issue: 1907 Volume: 11

daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Wed Oct 8 06:09:39 2008

Date: Wed, 8 Oct 2008 03:09:06 -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           Wed, 8 Oct 2008     Volume: 11 Number: 1907

Today's topics:
    Re: <Help> How to use routines from another perl script <hansmu@xs4all.nl>
    Re: <Help> How to use routines from another perl script <tim@burlyhost.com>
    Re: Data File charley@pulsenet.com
    Re: Data File <ben@morrow.me.uk>
    Re: efficient way to write multiple loops code sln@netherlands.com
    Re: efficient way to write multiple loops code <nospam-abuse@ilyaz.org>
    Re: efficient way to write multiple loops code sln@netherlands.com
    Re: Need to remove an array from another array <jurgenex@hotmail.com>
    Re: Need to remove an array from another array sln@netherlands.com
    Re: Need to remove an array from another array <me@privacy.invalid>
    Re: Need to remove an array from another array <me@privacy.invalid>
    Re: Need to remove an array from another array <jurgenex@hotmail.com>
    Re: Need to remove an array from another array sln@netherlands.com
        new CPAN modules on Wed Oct  8 2008 (Randal Schwartz)
    Re: sysread <ben@morrow.me.uk>
        Digest Administrivia (Last modified: 6 Apr 01) (Perl-Users-Digest Admin)

----------------------------------------------------------------------

Date: Wed, 08 Oct 2008 00:45:57 +0200
From: Hans Mulder <hansmu@xs4all.nl>
Subject: Re: <Help> How to use routines from another perl script
Message-Id: <48ebe75b$0$192$e4fe514c@news.xs4all.nl>

Tim Greer wrote:
> Petr Vileta (fidokomik) wrote:

>> #!/usr/bin/perl
> 
> use warnings;
> 
>> use strict;
>> require "/var/myroutines/ex1.pl;
> 
> || die, or die, or use eval.

Why use "die?  "Require" already "die"s when something is wrong.

Were you thinking of "do", perhaps?

-- HansM



------------------------------

Date: Tue, 07 Oct 2008 16:01:57 -0700
From: Tim Greer <tim@burlyhost.com>
Subject: Re: <Help> How to use routines from another perl script
Message-Id: <GTRGk.14$jX5.0@newsfe08.iad>

Hans Mulder wrote:

> Tim Greer wrote:
>> Petr Vileta (fidokomik) wrote:
> 
>>> #!/usr/bin/perl
>> 
>> use warnings;
>> 
>>> use strict;
>>> require "/var/myroutines/ex1.pl;
>> 
>> || die, or die, or use eval.
> 
> Why use "die?  "Require" already "die"s when something is wrong.
> 
> Were you thinking of "do", perhaps?
> 

I was actually making a point about the error (typo) he made in his
example... as in "what did you want it to do here?" in an attempt at
humor.

Notice:

require "/var/myroutines/ex1.pl;

is missing the closing ".  Sorry, that probably came out more sarcastic
than humorous (it was meant in a lighthearted way), but I was serious
about checking the calls.
-- 
Tim Greer, CEO/Founder/CTO, BurlyHost.com, Inc.
Shared Hosting, Reseller Hosting, Dedicated & Semi-Dedicated servers
and Custom Hosting.  24/7 support, 30 day guarantee, secure servers.
Industry's most experienced staff! -- Web Hosting With Muscle!


------------------------------

Date: Tue, 7 Oct 2008 15:31:54 -0700 (PDT)
From: charley@pulsenet.com
Subject: Re: Data File
Message-Id: <1844c89e-ecd6-4b86-b67c-c43402155b94@l33g2000pri.googlegroups.com>

On Oct 7, 5:21=A0pm, Ben Morrow <b...@morrow.me.uk> wrote:
> Quoth "friend...@gmail.com" <hirenshah...@gmail.com>:
>
> > On Oct 6, 6:01=A0pm, J=FCrgen Exner <jurge...@hotmail.com> wrote:
> > > "friend...@gmail.com" <hirenshah...@gmail.com> wrote:
> > > >On Oct 6, 12:52=A0pm, J=FCrgen Exner <jurge...@hotmail.com> wrote:
> > > >> [Forwarded from CLP.Modules]
>
> > > >> "friend...@gmail.com" <hirenshah...@gmail.com> wrote:
> > > >> >I have a large file in following format:
>
> > > >> >ID | Time | IP | Code
> <snip>
>
> > How can read file in Hash Array.
>
> > open(INFO, $file);
>
> *Always* check the return value of open.
> Use lexical filehandles.
> Use 3-arg open.
>
> =A0 =A0 open(my $INFO, "<", $file) or die "can't read '$file': $!";
>
> > @lines =3D <INFO>;
>
> Do you have 'use strict' at the top of your program?
>
> > # Instead of reading it in array. I want to put it in Hash Array(%).
> > And may just ID and IP fields.
>
> =A0 =A0 my %lines;
> =A0 =A0 @lines{qw/ID Time IP Code/} =3D <$INFO>;

Seems you'de want:
    @lines{qw/ID Time IP Code/} =3D split /\|/, <$INFO>;


>
> If you want just some fields, it is a little messier:
>
> =A0 =A0 my %lines;
> =A0 =A0 ($lines{ID}, undef, $lines{IP}, undef) =3D <$INFO>;

Same as above (using split)


>
> Ben
>
> --
> And if you wanna make sense / Whatcha looking at me for? =A0 =A0 =A0 =A0 =
=A0(Fiona Apple)
> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 * b...@morrow.me.=
uk *



------------------------------

Date: Wed, 8 Oct 2008 00:06:22 +0100
From: Ben Morrow <ben@morrow.me.uk>
Subject: Re: Data File
Message-Id: <ek6tr5-4sp.ln1@osiris.mauzo.dyndns.org>


Quoth charley@pulsenet.com:
> On Oct 7, 5:21 pm, Ben Morrow <b...@morrow.me.uk> wrote:
> >
> >     my %lines;
> >     @lines{qw/ID Time IP Code/} = <$INFO>;
> 
> Seems you'de want:
>     @lines{qw/ID Time IP Code/} = split /\|/, <$INFO>;

Yes, of course. Thank you.

Ben

-- 
        I must not fear. Fear is the mind-killer. I will face my fear and
        I will let it pass through me. When the fear is gone there will be 
        nothing. Only I will remain.
ben@morrow.me.uk                                          Frank Herbert, 'Dune'


------------------------------

Date: Tue, 07 Oct 2008 22:20:06 GMT
From: sln@netherlands.com
Subject: Re: efficient way to write multiple loops code
Message-Id: <h0one4l99t4td72mt0tn4hs3cjabdddcvo@4ax.com>

On Tue, 7 Oct 2008 13:31:50 -0700 (PDT), "friend.05@gmail.com" <hirenshah.05@gmail.com> wrote:

>Hi,
>
>I am trying to analyze some data. I have big data files.
>
>I have 3 different files in following format. ($file_1, $file_2,
>$file_3)
>
>ID | Time | IP | Code
>
>Following is psuedo code which I am writing. I want to know another
>efficient way to do same thing.
>
>open(INFO_1,$file_1);
>open(INFO_2,$file_2);
>open(INFO_3,$file_3);
>
>@file1_lines = <INFO_1>;
>@file2_lines = <INFO_2>;
>@file3_lines = <INFO_3>;
>
>foreach $file1_line (@file1_lines)
>{
>         @file1 = split('\|',$file1_line);
>
>         #some code
>
>         foreach $file2_line (@file2_lines)
>         {
>                 @file2 = split('\|',$file2_line);
>
>                 #some code
>
>                 #if condition between File1 data and File2 data
>                 {
>
>                  #some code
>
>                            foreach $file3_line (@file3_lines)
>                            {
>                                     @file3 = split('\|',$file3_line);
>
>                                     #some code
>
>                                    #if condition
>
>                            }
>
>                 }
>
>
>         }
>
>
>}
>
>
>
>So I am going thorugh each data of file 1 and depending on if data is
>present in file2 and again depending on some if condition I look for
>that data in file3.
>
>
>So each data of file1 will have to go through each data of file2 and
>each data of file2 will have to go thorugh file3.
>
>So this code is taking lot of time. I want some suggestion for
>efficient code.
>
>Can I use Hash Array (by reading file in  hash array)
>

Nobody knows the impact of any pseudo code, or what data that
it process is. There is no generalization to be sought.

The best you can do, through trial and error, is benchmark
it yourself:

use Benchmark ':hireswallclock';
my $t0 = new Benchmark;

{{{{ code block}}}

my $t1 = new Benchmark;
my $tdif = timediff($t1, $t0);
print STDERR "the code took:",timestr($tdif),"\n";

sln



------------------------------

Date: Tue, 7 Oct 2008 23:15:37 +0000 (UTC)
From:  Ilya Zakharevich <nospam-abuse@ilyaz.org>
Subject: Re: efficient way to write multiple loops code
Message-Id: <gcgqip$2r3u$1@agate.berkeley.edu>

[A complimentary Cc of this posting was sent to
friend.05@gmail.com
<hirenshah.05@gmail.com>], who wrote in article <4d1cfa08-ae0a-40e0-8073-258ef6484d50@a29g2000pra.googlegroups.com>:

Nobody else commented on that yet:

> @file1_lines = <INFO_1>;
> @file2_lines = <INFO_2>;
> @file3_lines = <INFO_3>;
> 
> foreach $file1_line (@file1_lines)
> {
>          @file1 = split('\|',$file1_line);

>          foreach $file2_line (@file2_lines)
>          {
>                  @file2 = split('\|',$file2_line);

This split is done again and again, once per every line of INFO_1.
The result is going to be the same anyway.  Better move it outside of
the loop

  @file2_fields = map [split '\|', $_], @file2_lines;

if you have enough memory.  Likewise for other stuff.

Hope this helps,
Ilya


------------------------------

Date: Wed, 08 Oct 2008 08:18:43 GMT
From: sln@netherlands.com
Subject: Re: efficient way to write multiple loops code
Message-Id: <h0roe4h0jlhpeuilb9gnveolpj3159p20t@4ax.com>

On Tue, 07 Oct 2008 22:20:06 GMT, sln@netherlands.com wrote:

>On Tue, 7 Oct 2008 13:31:50 -0700 (PDT), "friend.05@gmail.com" <hirenshah.05@gmail.com> wrote:
>
>>Hi,
>>
>>I am trying to analyze some data. I have big data files.
>>
>>I have 3 different files in following format. ($file_1, $file_2,
>>$file_3)
>>
>>ID | Time | IP | Code
>>
>>Following is psuedo code which I am writing. I want to know another
>>efficient way to do same thing.
>>
>>open(INFO_1,$file_1);
>>open(INFO_2,$file_2);
>>open(INFO_3,$file_3);
>>
>>@file1_lines = <INFO_1>;
>>@file2_lines = <INFO_2>;
>>@file3_lines = <INFO_3>;
>>
>>foreach $file1_line (@file1_lines)
>>{
>>         @file1 = split('\|',$file1_line);
>>
>>         #some code
>>
>>         foreach $file2_line (@file2_lines)
>>         {
>>                 @file2 = split('\|',$file2_line);
>>
>>                 #some code
>>
>>                 #if condition between File1 data and File2 data
>>                 {
>>
>>                  #some code
>>
>>                            foreach $file3_line (@file3_lines)
>>                            {
>>                                     @file3 = split('\|',$file3_line);
>>
>>                                     #some code
>>
>>                                    #if condition
>>
>>                            }
>>
>>                 }
>>
>>
>>         }
>>
>>
>>}
>>
>>
>>
>>So I am going thorugh each data of file 1 and depending on if data is
>>present in file2 and again depending on some if condition I look for
>>that data in file3.
>>
>>
>>So each data of file1 will have to go through each data of file2 and
>>each data of file2 will have to go thorugh file3.
>>
>>So this code is taking lot of time. I want some suggestion for
>>efficient code.
>>
>>Can I use Hash Array (by reading file in  hash array)
>>
>
>Nobody knows the impact of any pseudo code, or what data that
>it process is. There is no generalization to be sought.
>
>The best you can do, through trial and error, is benchmark
>it yourself:
>
>use Benchmark ':hireswallclock';
>my $t0 = new Benchmark;
>
>{{{{ code block}}}
>
>my $t1 = new Benchmark;
>my $tdif = timediff($t1, $t0);
>print STDERR "the code took:",timestr($tdif),"\n";
>
>sln

Well, if it were my code, I would know exactly how to do it without benchmarks.
But you don't know yourself it seams. Do you?
Instead, you post phoney PSEUDO code as if you know something, which you don't.
Yet put the burdon on the sucker who is stupid enough to respond to you.

Outta here... ignant

sln



------------------------------

Date: Tue, 07 Oct 2008 16:45:21 -0700
From: Jürgen Exner <jurgenex@hotmail.com>
Subject: Re: Need to remove an array from another array
Message-Id: <43tne4dsbm9g6b658l1ua2bc6as1n6mplu@4ax.com>

"M.L." <me@privacy.invalid> wrote:
>Given an array: @planets = qw(mercury venus earth mars jupiter saturn uranus
>neptune pluto);
>and @removes = qw(venus mars pluto);

perldoc -q intersection:
"How do I compute the difference of two arrays?  How do I compute the
intersection of two arrays?"

jue


------------------------------

Date: Wed, 08 Oct 2008 01:34:25 GMT
From: sln@netherlands.com
Subject: Re: Need to remove an array from another array
Message-Id: <6c3oe49k3g6hkpgn5tmgjvv7tk923qji4n@4ax.com>

On Tue, 7 Oct 2008 12:36:41 -0500, "M.L." <me@privacy.invalid> wrote:

>Given an array: @planets = qw(mercury venus earth mars jupiter saturn uranus
>neptune pluto);
>and @removes = qw(venus mars pluto);
>
>I'd like to know how to grep the @removes from @planets such that
>@planets = qw(mercury earth jupiter saturn uranus neptune);
>
>I tried
>@planets = grep (!/$removes[0..$#removes]/, @planets);
>but that didn't work and I'm out of ideas. Any assistance appreciated.
>Thanks.
>
> 
Why don't you just say it in English, do you really need examples?

The most important array comparison is thier similarity, not the difference!!!
Similarity first, difference by default.

sln


------------------------------

Date: Wed, 8 Oct 2008 00:16:38 -0500
From: "M.L." <me@privacy.invalid>
Subject: Re: Need to remove an array from another array
Message-Id: <gchfnf$gen$1@registered.motzarella.org>

>> Given an array: @planets = qw(mercury venus earth mars jupiter saturn 
>> uranus
>> neptune pluto);
>> and @removes = qw(venus mars pluto);
>
> A standard way would be to 'upgrade' the @removes array to ans hash
> and then use the existance of a key in the has as the condition for a
> grep:
>
> %removes = map { $_ => 1 } @removes;
> @planets = grep { !$remove{$_} } @planets;

I found your solution to be not only elegant, but the easiest to understand. 
After making a slight correction ($remove{$_}  -> $removes{$_} ), your 
solution worked like a charm. Thank you so much. 



------------------------------

Date: Wed, 8 Oct 2008 00:20:05 -0500
From: "M.L." <me@privacy.invalid>
Subject: Re: Need to remove an array from another array
Message-Id: <gchftr$h54$1@registered.motzarella.org>

>>Given an array: @planets = qw(mercury venus earth mars jupiter saturn 
>>uranus
>>neptune pluto);
>>and @removes = qw(venus mars pluto);
>
> perldoc -q intersection:
> "How do I compute the difference of two arrays?  How do I compute the
> intersection of two arrays?"

Thank you for your perldoc reference. While it provided a little more 
horsepower than I needed, I found it very enlightening. I'll keep it in my 
Perl notes file. 



------------------------------

Date: Tue, 07 Oct 2008 22:37:08 -0700
From: Jürgen Exner <jurgenex@hotmail.com>
Subject: Re: Need to remove an array from another array
Message-Id: <c9hoe494ir0fglrn8vsl2q854t6mt4e24m@4ax.com>

"M.L." <me@privacy.invalid> wrote:
>Given an array: @planets = qw(mercury venus earth mars jupiter saturn uranus
>neptune pluto);
>and @removes = qw(venus mars pluto);
>
>I'd like to know how to grep the @removes from @planets such that
>@planets = qw(mercury earth jupiter saturn uranus neptune);

Coming to think of it, your spec via example is rather incomplete:
- what about if @planets contains multiple entries with the same value,
e.g. 'mars'? Are you supposed to remove all occurences of 'mars' from
@planets, even if @removes contains only one entry 'mars'? And if only
one is to be removed, then which one? Any? The first? 
-probably less critical: what about if @removes contain an element that
is not part of @planets? Error? Or just ignore?

It appears to me you are using the arrays to represent mathematical
sets: elements are unique and sequence doesn't matter. If this is true,
then a hash would be a much better data structure.

jue


------------------------------

Date: Wed, 08 Oct 2008 08:04:01 GMT
From: sln@netherlands.com
Subject: Re: Need to remove an array from another array
Message-Id: <69qoe4lrbnlkea6pmavu7m345ar9sv98ve@4ax.com>

On Wed, 8 Oct 2008 00:16:38 -0500, "M.L." <me@privacy.invalid> wrote:

>>> Given an array: @planets = qw(mercury venus earth mars jupiter saturn 
>>> uranus
>>> neptune pluto);
>>> and @removes = qw(venus mars pluto);
>>
>> A standard way would be to 'upgrade' the @removes array to ans hash
>> and then use the existance of a key in the has as the condition for a
>> grep:
>>
>> %removes = map { $_ => 1 } @removes;
>> @planets = grep { !$remove{$_} } @planets;
>
>I found your solution to be not only elegant, but the easiest to understand. 
>After making a slight correction ($remove{$_}  -> $removes{$_} ), your 
>solution worked like a charm. Thank you so much. 

It just makes me sick listening to crap like this. I wan't to puke in your face.

sln



------------------------------

Date: Wed, 8 Oct 2008 04:42:22 GMT
From: merlyn@stonehenge.com (Randal Schwartz)
Subject: new CPAN modules on Wed Oct  8 2008
Message-Id: <K8EL2M.wC3@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.

App-Hachero-0.01
http://search.cpan.org/~danjou/App-Hachero-0.01/
a plaggable log analyzing framework 
----
Badger-0.03
http://search.cpan.org/~abw/Badger-0.03/
Perl Application Programming Toolkit 
----
CGI-Application-Plugin-Routes-0.01
http://search.cpan.org/~porta/CGI-Application-Plugin-Routes-0.01/
CGI::Application::Plugin::Routes 
----
CGI-Application-Plugin-Routes-0.02
http://search.cpan.org/~porta/CGI-Application-Plugin-Routes-0.02/
CGI::Application::Plugin::Routes 
----
CGI-Compress-Gzip-1.00
http://search.cpan.org/~cdolan/CGI-Compress-Gzip-1.00/
CGI with automatically compressed output 
----
Catalyst-Authentication-Credential-Flickr-0.02
http://search.cpan.org/~blom/Catalyst-Authentication-Credential-Flickr-0.02/
Flickr authentication for Catalyst 
----
Config-Inetd-0.30
http://search.cpan.org/~schubiger/Config-Inetd-0.30/
Interface inetd's configuration file 
----
DB2-db-0.22
http://search.cpan.org/~dmcbride/DB2-db-0.22/
Framework wrapper around DBD::DB2 for a specific database 
----
DBIx-Class-InflateColumn-FS-0.01000
http://search.cpan.org/~mmims/DBIx-Class-InflateColumn-FS-0.01000/
store BLOBs in the file system 
----
DDumper-0.16
http://search.cpan.org/~hmbrand/DDumper-0.16/
Modified and extended debugging facilities 
----
Dist-Zilla-1.001
http://search.cpan.org/~rjbs/Dist-Zilla-1.001/
distribution builder; installer not included! 
----
Doc-Simply-0.01
http://search.cpan.org/~rkrimen/Doc-Simply-0.01/
Generate POD-like documentation from embedded comments in JavaScript, Java, C, C++ source 
----
Finance-Quote-1.13_01
http://search.cpan.org/~ecocode/Finance-Quote-1.13_01/
Get stock and mutual fund quotes from various exchanges 
----
Git-Fingerd-1.000
http://search.cpan.org/~rjbs/Git-Fingerd-1.000/
let people finger your git server for... some reason 
----
HTML-Query-0.01
http://search.cpan.org/~abw/HTML-Query-0.01/
jQuery-like selection queries for HTML::Element 
----
Kx-0.036
http://search.cpan.org/~markpf/Kx-0.036/
Perl extension for Kdb+ http://kx.com 
----
LEOCHARRE-Test-1.03
http://search.cpan.org/~leocharre/LEOCHARRE-Test-1.03/
personal testing subs 
----
LEOCHARRE-Test-1.04
http://search.cpan.org/~leocharre/LEOCHARRE-Test-1.04/
personal testing subs 
----
LaTeX-Table-0.9.6
http://search.cpan.org/~limaone/LaTeX-Table-0.9.6/
Perl extension for the automatic generation of LaTeX tables. 
----
Linux-Inotify2-1.2
http://search.cpan.org/~mlehmann/Linux-Inotify2-1.2/
scalable directory/file change notification 
----
MIME-Structure-0.06
http://search.cpan.org/~nkuitse/MIME-Structure-0.06/
determine structure of MIME messages 
----
Math-RungeKutta-1.05
http://search.cpan.org/~pjb/Math-RungeKutta-1.05/
Integrating Systems of Differential Equations 
----
Mixin-ExtraFields-Driver-DBIC-0.003
http://search.cpan.org/~rjbs/Mixin-ExtraFields-Driver-DBIC-0.003/
store Mixin::ExtraFields data in a DBIx::Class store 
----
Module-Setup-0.03
http://search.cpan.org/~yappo/Module-Setup-0.03/
a simple module maker "yet another Module::Start(?:er)?" 
----
Net-DNS-ZoneFile-Fast-1.01
http://search.cpan.org/~hardaker/Net-DNS-ZoneFile-Fast-1.01/
parse BIND8/9 zone files 
----
Net-Finger-Server-0.003
http://search.cpan.org/~rjbs/Net-Finger-Server-0.003/
a simple finger server 
----
Number-Tolerant-1.601
http://search.cpan.org/~rjbs/Number-Tolerant-1.601/
tolerance ranges for inexact numbers 
----
POE-Component-CPANPLUS-YACSmoke-1.48
http://search.cpan.org/~bingos/POE-Component-CPANPLUS-YACSmoke-1.48/
Bringing the power of POE to CPAN smoke testing. 
----
POE-Component-CPANPLUS-YACSmoke-1.50
http://search.cpan.org/~bingos/POE-Component-CPANPLUS-YACSmoke-1.50/
Bringing the power of POE to CPAN smoke testing. 
----
POE-Component-SmokeBox-0.01_04
http://search.cpan.org/~bingos/POE-Component-SmokeBox-0.01_04/
POE enabled CPAN smoke testing with added value. 
----
Parse-Eyapp-1.118
http://search.cpan.org/~casiano/Parse-Eyapp-1.118/
Extensions for Parse::Yapp 
----
Rose-DBx-Object-Renderer-0.38
http://search.cpan.org/~danny/Rose-DBx-Object-Renderer-0.38/
Web UI Rendering for Rose::DB::Object 
----
TVDB-API-0.22
http://search.cpan.org/~behanw/TVDB-API-0.22/
API to www.thetvdb.com 
----
WWW-Bugzilla3-0.71
http://search.cpan.org/~swined/WWW-Bugzilla3-0.71/
perl bindings for Bugzilla 3.0 api 
----
WWW-Netflix-API-0.01
http://search.cpan.org/~davidrw/WWW-Netflix-API-0.01/
Interface for Netflix's API 
----
WebService-Solr-0.01
http://search.cpan.org/~bricas/WebService-Solr-0.01/
Module to interface with the Solr (Lucene) webservice 
----
XML-RSS-1.36
http://search.cpan.org/~shlomif/XML-RSS-1.36/
creates and updates RSS files 
----
XML-Rewrite-0.10
http://search.cpan.org/~markov/XML-Rewrite-0.10/
schema based XML cleanups 
----
qn-0.02
http://search.cpan.org/~jrm/qn-0.02/
Perl extension for quoting and splitting on newlines. 
----
rgit-0.04
http://search.cpan.org/~vpit/rgit-0.04/
Recursively execute a command on all the git repositories in a directory tree. 


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/>
Smalltalk/Perl/Unix consulting, Technical writing, Comedy, etc. etc.
See http://methodsandmessages.vox.com/ for Smalltalk and Seaside discussion


------------------------------

Date: Tue, 7 Oct 2008 23:15:23 +0100
From: Ben Morrow <ben@morrow.me.uk>
Subject: Re: sysread
Message-Id: <rk3tr5-nhn.ln1@osiris.mauzo.dyndns.org>


Quoth Hans Mulder <hansmu@xs4all.nl>:
> Ben Morrow wrote:
> > Quoth Larry <dontmewithme@got.it>:
> >> In article <slrngek930.67p.tadmc@tadmc30.sbcglobal.net>,
> >>  Tad J McClellan <tadmc@seesig.invalid> wrote:
> >>
> >>> http://perl.plover.com/FAQs/Buffering.html
> >> Thanks, I read that. Too bad my system (Mac OS X) doesn't support: 
> >> setvbuf();
> > 
> > Modern perls (as of 5.8) use PerlIO instead of stdio, so what your
> > system supports is irrelevant. 
> 
> The stdio on my Mac OS X system supports setvbuf(), but perlIO does not.
> For example, if I do:
> 
> use IO::Handle '_IOFBF';
> open FH, "</etc/motd" or die $!;
> FH->setvbuf($buffer_var, _IOFBF, 8151);
> 
> , I get:
> 
> IO::Handle::setvbuf not implemented on this architecture at t.pl line 3.

Yes. From perldoc IO::Handle:

    WARNING: The IO::Handle::setvbuf() is not available by default on
    Perls 5.8.0 and later because setvbuf() is rather specific to using
    the stdio library, while Perl prefers the new perlio subsystem
    instead.

If you need to use your own buffer, push :unix (or just use sysread) and
do it by hand.

Ben

-- 
"Faith has you at a disadvantage, Buffy."
"'Cause I'm not crazy, or 'cause I don't kill people?"
"Both, actually."
                                                         [ben@morrow.me.uk]


------------------------------

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 1907
***************************************


home help back first fref pref prev next nref lref last post