in reply to Retrieving a List of directories only
#!/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 |