[30000] in Perl-Users-Digest

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

Perl-Users Digest, Issue: 1243 Volume: 11

daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Wed Jan 30 16:09:45 2008

Date: Wed, 30 Jan 2008 13:09:07 -0800 (PST)
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, 30 Jan 2008     Volume: 11 Number: 1243

Today's topics:
    Re: "negative" regexp <stoupa@practisoft.cz>
    Re: "negative" regexp <bik.mido@tiscalinet.it>
    Re: "negative" regexp <tzz@lifelogs.com>
    Re: C's gotoxy() equivalent in Perl <ben@morrow.me.uk>
    Re: C's gotoxy() equivalent in Perl <invalid@invalid.net>
        Can't call NEXT::f from B::g <porton@narod.ru>
    Re: Can't call NEXT::f from B::g <peter@makholm.net>
    Re: Can't call NEXT::f from B::g <porton@narod.ru>
    Re: Can't call NEXT::f from B::g <bik.mido@tiscalinet.it>
        fork and hanging <newtan@gmail.com>
    Re: fork and hanging xhoster@gmail.com
    Re: Get an arbitrary hash key, quickly. <simon.chao@fmr.com>
    Re: Get an arbitrary hash key, quickly. <simon.chao@fmr.com>
    Re: Get an arbitrary hash key, quickly. <simon.chao@fmr.com>
    Re: Get an arbitrary hash key, quickly. xhoster@gmail.com
    Re: Get an arbitrary hash key, quickly. <simon.chao@fmr.com>
    Re: List of directories within a directory <nospam@nospam.com>
        Digest Administrivia (Last modified: 6 Apr 01) (Perl-Users-Digest Admin)

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

Date: Wed, 30 Jan 2008 16:10:15 +0100
From: "Petr Vileta" <stoupa@practisoft.cz>
Subject: Re: "negative" regexp
Message-Id: <fnq47i$29q8$1@ns.felk.cvut.cz>

Abigail wrote:
>                                            _
> Petr Vileta (stoupa@practisoft.cz) wrote on VCCLXV September MCMXCIII
> in <URL:news:fnoj8a$1hin$1@ns.felk.cvut.cz>:
> ;;  I have problem to construct regexp, this is out of my brain ;-)
> please help. ;;
> ;;  I have string
> ;;
> ;;  $string="<a href='big.gif'><img src='small.gif'></a><br><a
> ;;  href='abc.htm'><b>click</b></a>";
> ;;
> ;;  and I need to remove all html tags except <img ...>. The result
> should be ;;
> ;;  $string="<img src='small.gif'>click";
> ;;
>
> Well, for your example,
>
>    s/<(?!img)[^>]*>//g
>
Thanks, this work OK.

>
> The "right" way to do it is to use a proper HTML parser.
>
> Get one from your nearest CPAN.
>
I'm tending to not use HTMP parsers because these construct a huge hashes and 
this is usually not needed for my purposes.
-- 
Petr Vileta, Czech republic
(My server rejects all messages from Yahoo and Hotmail. Send me your
mail from another non-spammer site please.)

Please reply to <petr AT practisoft DOT cz>



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

Date: Wed, 30 Jan 2008 17:47:04 +0100
From: Michele Dondi <bik.mido@tiscalinet.it>
Subject: Re: "negative" regexp
Message-Id: <sfa1q31spn2uilu69quu04d7p1i8959ihd@4ax.com>

On Wed, 30 Jan 2008 16:10:15 +0100, "Petr Vileta"
<stoupa@practisoft.cz> wrote:

>I'm tending to not use HTMP parsers because these construct a huge hashes and 
>this is usually not needed for my purposes.

Huh?!? Evidence?


Michele
-- 
{$_=pack'B8'x25,unpack'A8'x32,$a^=sub{pop^pop}->(map substr
(($a||=join'',map--$|x$_,(unpack'w',unpack'u','G^<R<Y]*YB='
 .'KYU;*EVH[.FHF2W+#"\Z*5TI/ER<Z`S(G.DZZ9OX0Z')=~/./g)x2,$_,
256),7,249);s/[^\w,]/ /g;$ \=/^J/?$/:"\r";print,redo}#JAPH,


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

Date: Wed, 30 Jan 2008 12:58:04 -0600
From: Ted Zlatanov <tzz@lifelogs.com>
Subject: Re: "negative" regexp
Message-Id: <86y7a716pv.fsf@lifelogs.com>

On Wed, 30 Jan 2008 17:47:04 +0100 Michele Dondi <bik.mido@tiscalinet.it> wrote: 

MD> On Wed, 30 Jan 2008 16:10:15 +0100, "Petr Vileta"
MD> <stoupa@practisoft.cz> wrote:

>> I'm tending to not use HTMP parsers because these construct a huge hashes and 
>> this is usually not needed for my purposes.

MD> Huh?!? Evidence?

Well, it's right in the name: Huge Temporary Memory Packrat, HTMP.  I
try not to use HTMP parsers myself as well for this very reason.

Ted


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

Date: Wed, 30 Jan 2008 14:12:45 +0000
From: Ben Morrow <ben@morrow.me.uk>
Subject: Re: C's gotoxy() equivalent in Perl
Message-Id: <t7d675-4je.ln1@osiris.mauzo.dyndns.org>


Quoth "Gerry Ford" <invalid@invalid.net>:
> "Yogi" <yogeshkagrawal@gmail.com> wrote in message 
> news:7bb7b711-0fbb-423a-9d5a-f134a1e78133@k2g2000hse.googlegroups.com...
> >
> > Thanks John for providing me link.  I believe, I will have to install
> > Curses as its not available in perl version I am using.
>
> Maybe one way to get what you want is to install Ruby and borrow the curses. 
> I frankly don't know a curse from a gem or a rake, but since Ruby was 
> created using MVC++6, it might be better for windows stuff than the 
> equivalent from perl.

ActivePerl is build using MSVC6, and if the OP has MSVC (and Curses will
build under Windows at all) it will build perfectly well. Also, recent
versions of ActivePerl have some provision for using MinGW to build
modules that are compatible with perl.

Ben



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

Date: Wed, 30 Jan 2008 09:04:48 -0700
From: "Gerry Ford" <invalid@invalid.net>
Subject: Re: C's gotoxy() equivalent in Perl
Message-Id: <1201709174_587@sp12lax.superfeed.net>


"Ben Morrow" <ben@morrow.me.uk> wrote in message 
news:t7d675-4je.ln1@osiris.mauzo.dyndns.org...
>
> Quoth "Gerry Ford" <invalid@invalid.net>:
>> "Yogi" <yogeshkagrawal@gmail.com> wrote in message
>> news:7bb7b711-0fbb-423a-9d5a-f134a1e78133@k2g2000hse.googlegroups.com...
>> >
>> > Thanks John for providing me link.  I believe, I will have to install
>> > Curses as its not available in perl version I am using.
>>
>> Maybe one way to get what you want is to install Ruby and borrow the 
>> curses.
>> I frankly don't know a curse from a gem or a rake, but since Ruby was
>> created using MVC++6, it might be better for windows stuff than the
>> equivalent from perl.
>
> ActivePerl is build using MSVC6, and if the OP has MSVC (and Curses will
> build under Windows at all) it will build perfectly well. Also, recent
> versions of ActivePerl have some provision for using MinGW to build
> modules that are compatible with perl.

Good Grief!  I thought I was a certifiable dinosaur to even possess MVC 4 
and 6, unwilling as I was to cross the dot net threshold, and now you say 
it's building the scripting languages on the world's platform of choice.  Do 
you know of any web resources that talk about how MVC can augment an AS or a 
Ruby install?
--  




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

Date: Wed, 30 Jan 2008 06:40:54 -0800 (PST)
From: Victor Porton <porton@narod.ru>
Subject: Can't call NEXT::f from B::g
Message-Id: <ce00fff7-8d80-4079-a6a7-e1e3664393a3@h11g2000prf.googlegroups.com>

$ perl test.pl
Can't call NEXT::f from B::g at /home/porton/t/test2.pl line 10

Why the error?

#!/usr/bin/perl -w

use NEXT;

package A;
sub f { print "123\n" }

package B;
use base 'A';
sub g { shift->NEXT::f }

B->g;


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

Date: Wed, 30 Jan 2008 14:47:11 +0000
From: Peter Makholm <peter@makholm.net>
Subject: Re: Can't call NEXT::f from B::g
Message-Id: <87myqnjrps.fsf@hacking.dk>

Victor Porton <porton@narod.ru> writes:

> $ perl test.pl
> Can't call NEXT::f from B::g at /home/porton/t/test2.pl line 10
>
> Why the error?

Doesn't the following except from the documentation to NEXT explains
it?

   Note that it is a fatal error for any method (including "AUTOLOAD") to
   attempt to redispatch any method that does not have the same name. For
   example:

       sub D::oops { print "oops!\n"; $_[0]->NEXT::other_method() }

//Makholm


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

Date: Wed, 30 Jan 2008 07:51:26 -0800 (PST)
From: Victor Porton <porton@narod.ru>
Subject: Re: Can't call NEXT::f from B::g
Message-Id: <330edfb8-5f31-4270-a2a4-ce2869018d36@v29g2000hsf.googlegroups.com>

On 30 Jan, 16:47, Peter Makholm <pe...@makholm.net> wrote:
> Victor Porton <por...@narod.ru> writes:
> > $ perl test.pl
> > Can't call NEXT::f from B::g at /home/porton/t/test2.pl line 10
>
> > Why the error?
>
> Doesn't the following except from the documentation to NEXT explains
> it?
>
>    Note that it is a fatal error for any method (including "AUTOLOAD") to
>    attempt to redispatch any method that does not have the same name. For
>    example:
>
>        sub D::oops { print "oops!\n"; $_[0]->NEXT::other_method() }

Yes, that was my error.

New question: Why the below script does not print "123"?

#!/usr/bin/perl -w

use NEXT;

package A;
sub f { print "123\n" }

package B;
use base 'A';

package C;
use base 'B';
sub f { shift->NEXT::f }

C->f;


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

Date: Wed, 30 Jan 2008 17:56:30 +0100
From: Michele Dondi <bik.mido@tiscalinet.it>
Subject: Re: Can't call NEXT::f from B::g
Message-Id: <kia1q3dtcf6k9olabot1klrcn5flfe1991@4ax.com>

On Wed, 30 Jan 2008 07:51:26 -0800 (PST), Victor Porton
<porton@narod.ru> wrote:

>package A;
>sub f { print "123\n" }
>
>package B;
>use base 'A';

Incidentally, base.pm does more than you expect. You may want to just
set @ISA manually in this case.

Moreover, base.pm is regarded as buggy by some.

Moreover, do not try to use B as a generic namespace, since it
actually exists. In fact when I stumbled upon your subject, I thought
it had to do with Perl's opcodes...


Michele
-- 
{$_=pack'B8'x25,unpack'A8'x32,$a^=sub{pop^pop}->(map substr
(($a||=join'',map--$|x$_,(unpack'w',unpack'u','G^<R<Y]*YB='
 .'KYU;*EVH[.FHF2W+#"\Z*5TI/ER<Z`S(G.DZZ9OX0Z')=~/./g)x2,$_,
256),7,249);s/[^\w,]/ /g;$ \=/^J/?$/:"\r";print,redo}#JAPH,


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

Date: Wed, 30 Jan 2008 11:55:12 -0800 (PST)
From: nazrat <newtan@gmail.com>
Subject: fork and hanging
Message-Id: <715e6be3-7893-4afb-b8a7-cf11fdbb6445@z17g2000hsg.googlegroups.com>

I have been searching for the problem on the net but unable to get a
good answer so I'd like to post it here for help.

I have attempted to simultaneously ssh to a number of boxes (with
openssh 3.5p1 - 3.9p1) via forking subprocesses. However, there always
seem to be a few ssh sessions got stuck and thus, my control (parent)
process cannot exit. I have searched for similar problems regarding
ssh hanging with fork, but most results indicated that the issue was
on the remote machine with an inappropriately demonized process (ie.
not redirect 3 input streams). In my scenerio, the forking doesn't
happen on remote site and the remote command is just a simple one
(uname) as  demonstrated in the scripts enclosed below.

In this setting, I have an 'expect' script (spawn.exp) used to cache
the password and feed it to spawned processes (ssh.pl). I am not sure
if there is any animosity between Perl fork and ssh that I am not
aware of?

% ./spawn.exp ./ssh.pl

ssh.pl:

#!/usr/local/bin/perl -w
use strict;

my %pids;

for my $id ('01'..'05') {
    my $pid = fork();
    die "fork $id: $!\n" unless defined $pid;
    if ($pid == 0) {
        #open STDIN, '</dev/null';
        #open STDOUT, '>/dev/null';
        #open STDERR, '>/dev/null';
        exec 'ssh', "build-$id", 'uname', '-a';
    }
    else {
        $pids{$pid} = "build-$id";
    }
}
while (%pids) {
    my $pid = wait();
    last if $pid == -1;
    delete $pids{$pid} if exists $pids{$pid};
}

__END__


spawn.exp:

#!/usr/bin/expect --

set passwd ""
set timeout -1

eval spawn -noecho $argv
expect {
  "Please try again." {
    set passwd
    exp_continue
  }
  "password:" {
    if {$passwd == ""} {
      stty -echo
      send_user " (script) "
      expect_user -re "(.*)\n"
      stty echo
      set passwd $expect_out(1,string)
    } else {
      send_user " (supplied by script) "
    }
    send -- "$passwd\r"
    exp_continue
  }
}


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

Date: 30 Jan 2008 20:55:43 GMT
From: xhoster@gmail.com
Subject: Re: fork and hanging
Message-Id: <20080130155545.763$wd@newsreader.com>

nazrat <newtan@gmail.com> wrote:
>
> In this setting, I have an 'expect' script (spawn.exp) used to cache
> the password and feed it to spawned processes (ssh.pl). I am not sure
> if there is any animosity between Perl fork and ssh that I am not
> aware of?
>
> % ./spawn.exp ./ssh.pl

I think I'd try having ssh.pl call spawn.exp, not the other way around.
If a single expect is trying to talk to many different processes over
the same file handles at the same time, I wouldn't be surprised if things
often go awry.


 ...

>         exec 'ssh', "build-$id", 'uname', '-a';

   exec "./spawn.exp ssh build-$id uname -a";

Or something like that, I don't use expect.

Xho

-- 
-------------------- http://NewsReader.Com/ --------------------
The costs of publication of this article were defrayed in part by the
payment of page charges. This article must therefore be hereby marked
advertisement in accordance with 18 U.S.C. Section 1734 solely to indicate
this fact.


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

Date: Wed, 30 Jan 2008 07:31:09 -0800 (PST)
From: nolo contendere <simon.chao@fmr.com>
Subject: Re: Get an arbitrary hash key, quickly.
Message-Id: <c487b9ee-6267-4a7a-8865-2c0f74d0c6ce@v17g2000hsa.googlegroups.com>

On Jan 29, 11:38=A0am, Ben Morrow <b...@morrow.me.uk> wrote:
> Quoth nolo contendere <simon.c...@fmr.com>:
>
> > On Jan 28, 8:05=A0pm, Ben Morrow <b...@morrow.me.uk> wrote:
>
> > > It isn't. keys returns a list. What *is* true in this case is that if
> > > any entries you haven't got to yet are deleted from the hash, they wil=
l
>
> > hmm, I thought it was unsafe to delete any entries other than the one
> > just accessed.
>
> No, this is a misconception (though one that is somewhat supported by
> the docs). Seehttp://blog.plover.com/prog/perl/undefined.html#3.
> Deleting the current entry is actually the potentially-unsafe case, but
> perl special-cases it for you so it works correctly (the entry has to be
> deleted lazily, after the iterator has moved on to the next entry).
>

cool!

> In any case, none of this applies to
>
> =A0 =A0 for (keys %h) { ... }
>
> keys is in list context, so the complete list of keys is generated
> before the loop even starts iterating.
>
> > > still be in for's list and will be returned anyway; since that isn't t=
he
> > > case here, it doesn't matter.
>
> > right. my understanding is that for (and foreach) take a snapshot of
> > the list, and iterate through that snapshot.
>
> Not quite; keys returns a list which is a snapshot of the current set of
> keys. What you do with that list afterwards is irrelevant.
>

right, that was my understanding.

> > > However, I would have thought that as the number of keys gets larger,
> > > this get slower, since it has to build a complete list of the keys eac=
h
> > > time through QUEUE. Let's see...
>
> > wouldn't every subsequent list be smaller for the most part? unless
> > "do stuff" generated more keys than were deleted on average.
>
> No, that wasn't what I meant. I meant 'as the initial set of keys
> becomes large, perhaps building a complete list of that set becomes
> inefficient'. It seems it doesn't.
>

oh.


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

Date: Wed, 30 Jan 2008 07:31:32 -0800 (PST)
From: nolo contendere <simon.chao@fmr.com>
Subject: Re: Get an arbitrary hash key, quickly.
Message-Id: <5924958d-d9c7-4a34-8031-bf59aab99058@d70g2000hsb.googlegroups.com>

On Jan 29, 11:50=A0am, xhos...@gmail.com wrote:
> nolo contendere <simon.c...@gmail.com> wrote:
>
> > > QUEUE: {
> > > =3DA0 foreach my $to_do (keys %hash) {
> > > =3DA0 =3DA0 =3DA0delete $hash{$to_do};
> > > =3DA0 =3DA0 =3DA0## do stuff with $to_do, which might
> > > =3DA0 =3DA0 =3DA0 =3DA0 # make new entries in %hash
> > > =3DA0 }
> > > =3DA0 redo QUEUE if keys %hash;
>
> > > }
>
> > perldoc perlsyn:
> > =A0 =A0 =A0 =A0...
> > =A0 =A0 =A0 =A0If any part of LIST is an array, "foreach" will get very
> > confused if
> > =A0 =A0 =A0 =A0you add or remove elements within the loop body, for exam=
ple
> > with
> > =A0 =A0 =A0 =A0"splice". =A0 So don't do that.
>
> But in this case, no part of the LIST is an array. =A0keys %hash is not
> an array.
>

oops! newbie mistake, sorry!


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

Date: Wed, 30 Jan 2008 07:33:00 -0800 (PST)
From: nolo contendere <simon.chao@fmr.com>
Subject: Re: Get an arbitrary hash key, quickly.
Message-Id: <e86f33c8-75d0-46c4-8be2-0514ecfea67c@e23g2000prf.googlegroups.com>

On Jan 29, 12:20=A0pm, xhos...@gmail.com wrote:
> nolo contendere <simon.c...@fmr.com> wrote:
> > On Jan 28, 8:05=3DA0pm, Ben Morrow <b...@morrow.me.uk> wrote:
> > > Quoth nolo contendere <simon.c...@gmail.com>:
>
> > > > On Jan 28, 5:52=3DA0pm, "comp.llang.perl.moderated" <c...@blv-
> > > > sam-01.ca.boeing.com> wrote:
>
> > > > > Do you need 'each' since values don't seem
> > > > > to be retrieved...Some simple benchmarks
> > > > > suggest just looping over the keys would
> > > > > be quite a bit faster if that's the case:
>
> > > > > QUEUE: {
> > > > > =3DA0 foreach my $to_do (keys %hash) {
> > > > > =3DA0 =3DA0 =3DA0delete $hash{$to_do};
> > > > > =3DA0 =3DA0 =3DA0## do stuff with $to_do, which might
> > > > > =3DA0 =3DA0 =3DA0 =3DA0 # make new entries in %hash
> > > > > =3DA0 }
> > > > > =3DA0 redo QUEUE if keys %hash;
>
> > > > > }
>
> > > > perldoc perlsyn:
> > > > =3DA0 =3DA0 =3DA0 =3DA0...
> > > > =3DA0 =3DA0 =3DA0 =3DA0If any part of LIST is an array, "foreach" wi=
ll get
> > > > very
>
> > > =3DA0 =3DA0 =3DA0 =3DA0 =3DA0 =3DA0 =3DA0 =3DA0 =3DA0 =3DA0 =3DA0 =3DA=
0 =3DA0 =3DA0 =3DA0^^^^^^^^^^^
> > > It isn't. keys returns a list. What *is* true in this case is that if
> > > any entries you haven't got to yet are deleted from the hash, they wil=
l
>
> > hmm, I thought it was unsafe to delete any entries other than the one
> > just accessed.
>
> That is with "each %hash", not with "keys %hash".
>
>
>
> > > still be in for's list and will be returned anyway; since that isn't
> > > the case here, it doesn't matter.
>
> > right. my understanding is that for (and foreach) take a snapshot of
> > the list, and iterate through that snapshot.
>
> Except when the LIST of the foreach has an array in it, then it doesn't
> take a snapshot--it does something else (presumably as an optimization),
> the details of which are not documented but the effects of which are
> (weirdness when changing the array).
>

hmm, could you, or anyone with >=3D your knowledge about this subject
expound?


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

Date: 30 Jan 2008 15:48:46 GMT
From: xhoster@gmail.com
Subject: Re: Get an arbitrary hash key, quickly.
Message-Id: <20080130104847.932$F8@newsreader.com>

nolo contendere <simon.chao@fmr.com> wrote:
> On Jan 29, 12:20=A0pm, xhos...@gmail.com wrote:
> >
> > > right. my understanding is that for (and foreach) take a snapshot of
> > > the list, and iterate through that snapshot.
> >
> > Except when the LIST of the foreach has an array in it, then it doesn't
> > take a snapshot--it does something else (presumably as an
> > optimization), the details of which are not documented but the effects
> > of which are (weirdness when changing the array).
> >
>
> hmm, could you, or anyone with >=3D your knowledge about this subject
> expound?

I think the link to plover that Ben Morrow posted already did that.
It isn't actually weird, I just treat as weird because it isn't documented
and so could in theory do something different in other versions.

Well, OK, it is weird, because the docs "If any part of LIST is an array"
but it seems that, to get the behavior shown in the plover link, the
entirety of the LIST has to be an array.  if you do something like:

foreach ("foo",@x) {

Then it appears, at least on my version, that it does in fact take a
snapshot of @x (more properly, a snapshot of the addresses to the elements
in @x) and any splices made into it during the loop have no effect on the
iteration.

Xho

-- 
-------------------- http://NewsReader.Com/ --------------------
The costs of publication of this article were defrayed in part by the
payment of page charges. This article must therefore be hereby marked
advertisement in accordance with 18 U.S.C. Section 1734 solely to indicate
this fact.


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

Date: Wed, 30 Jan 2008 07:57:21 -0800 (PST)
From: nolo contendere <simon.chao@fmr.com>
Subject: Re: Get an arbitrary hash key, quickly.
Message-Id: <550c752f-7df3-4036-bfe7-1e2ab650e0b6@d70g2000hsb.googlegroups.com>

On Jan 30, 10:48=A0am, xhos...@gmail.com wrote:
> nolo contendere <simon.c...@fmr.com> wrote:
> > On Jan 29, 12:20=3DA0pm, xhos...@gmail.com wrote:
>
> > > > right. my understanding is that for (and foreach) take a snapshot of=

> > > > the list, and iterate through that snapshot.
>
> > > Except when the LIST of the foreach has an array in it, then it doesn'=
t
> > > take a snapshot--it does something else (presumably as an
> > > optimization), the details of which are not documented but the effects=

> > > of which are (weirdness when changing the array).
>
> > hmm, could you, or anyone with >=3D3D your knowledge about this subject
> > expound?
>
> I think the link to plover that Ben Morrow posted already did that.
> It isn't actually weird, I just treat as weird because it isn't documented=

> and so could in theory do something different in other versions.
>
> Well, OK, it is weird, because the docs "If any part of LIST is an array"
> but it seems that, to get the behavior shown in the plover link, the
> entirety of the LIST has to be an array. =A0if you do something like:
>
> foreach ("foo",@x) {
>
> Then it appears, at least on my version, that it does in fact take a
> snapshot of @x (more properly, a snapshot of the addresses to the elements=

> in @x) and any splices made into it during the loop have no effect on the
> iteration.
>

thanks Xho, I'll check out the plover site more thoroughly.


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

Date: Wed, 30 Jan 2008 09:58:56 -0500
From: Al Moodie <nospam@nospam.com>
Subject: Re: List of directories within a directory
Message-Id: <5241q3tu2873d8l7sptq77dniih4vro2i7@4ax.com>

On Wed, 30 Jan 2008 04:36:32 GMT, Jürgen Exner <jurgenex@hotmail.com>
wrote:

>Al Moodie <nospam@nospam.com> wrote:
>>I have a directory with 200 sub directories in it. How do I create a
>>list of the sub directory names?
>
>Didn't I just read exactly the same question from a name sake of yours in a
>different NG? You may want to read up on the difference between
>cross-posting (which is rarely appropriate) and multi-posting (which is
>never justified).
>
>Same answer as there: I would use File::Find and prune at a depth of 2.
>
>jue

Sorry, it seemed to me that comp.lang.perl was inactive, hence to
second post here. Now that I know comp.lang.perl.misc it will not
happen again.

Al Moodie.


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

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


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