in reply to printing the directories...

I think forms could help you. Or Text::Table.

And I think you're making it more difficult than it is:

use Text::Table; my $t = Text::Table->new(qw(CASENAME SORTED CLEANED PROCEED)); for my $dir (glob '/home/folders/case*/') { my @res; for my $subdir (qw(sorted cleaned proceed) { if (-d "$dir/$subdir") { push @res, 'Yes'; } else { push @res, 'No'; } } $t->add(@res); } print $t;

Untested, but should work that way (or with small modifications).

See -d for documentation of -d.

Replies are listed 'Best First'.
Re^2: printing the directories...
by blazar (Canon) on Oct 23, 2008 at 20:51 UTC
      Don't be mislead by that name. Although Perl6::Form was a prototype for something that was planned for Perl 6, Forms/formats aren't part of the language specification anymore (and to be handled by libraries instead).

      I've never been into formats, but have used Text::Table before, and I find its interface intuitive, and much more quickly to grasp than formats/forms magic.

        Don't be mislead by that name. Although Perl6::Form was a prototype for something that was planned for Perl 6, Forms/formats aren't part of the language specification anymore (and to be handled by libraries instead).

        AFAIKnew Forms/formats have never been part of the language specification and always been intended to be handled by libraries instead - but libraries that would be in core Perl 6, thus I don't think I've been mislead by the name: Perl6::Form still is by all means the prototype implementation of Perl 6's Form.pm.

        --
        If you can't understand the incipit, then please check the IPB Campaign.
Re^2: printing the directories...
by sugar (Beadle) on Oct 23, 2008 at 08:25 UTC
    thanks...the program gives me the desired results..though, i m not able to print the case names. pushing, $dir to @res doesnt help because its printing the full path and not the case folder name alone :(