in reply to Retrieving a List of directories only

this accepts multiple arguments,and uses a hash to build a unique directory list.

#!/usr/bin/perl require 5.006; use strict; use warnings; $|++; use File::Find (); my %dirs; while( $_ = shift @ARGV ) { next unless -d $_; File::Find::find sub{ -d $File::Find::name and $dirs{$File::Find::name} = undef }, $_; } print $_,$/ for sort keys %dirs;

~Particle *accelerates*

Replies are listed 'Best First'.
Re: Re: Retrieving a List of directories only
by blackadder (Hermit) on Jul 29, 2002 at 15:14 UTC
    Chaps and chapetts...You are all Brilliant.

    Thanks for this.

    PS : Any Chanse of help in my Drag and Drop problems,...please.