Skip to content

Instantly share code, notes, and snippets.

@leejarvis
Created May 25, 2010 11:07
Show Gist options
  • Save leejarvis/413018 to your computer and use it in GitHub Desktop.
Save leejarvis/413018 to your computer and use it in GitHub Desktop.
#!/usr/bin/perl -w
use strict;
use warnings;
use feature qw/say/;
sub search($) {
my $path = shift;
say "Path: $path";
for my $file (glob($path.'/*')) {
-d $file ? &search($file) : say "\t$file";
}
}
map {search($_)} grep +(-d $_), <*>;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment