PIR - Short alias for Path::Iterator::Rule
version 0.012
use PIR; my $rule = PIR->new; # match anything $rule->file->size(">10k"); # add/chain rules # iterator interface my $next = $rule->iter( @dirs ); while ( my $file = $next->() ) { ... } # list interface for my $file ( $rule->all( @dirs ) ) { ... }
This is an empty subclass of Path::Iterator::Rule. It saves you from having to type the full name repeatedly, which is particularly handy for one-liners:
$ perl -MPIR -wE 'say for PIR->new->skip_dirs(".")->perl_module->all(@INC)'
David Golden <dagolden@cpan.org>
This software is Copyright (c) 2013 by David Golden.
This is free software, licensed under:
The Apache License, Version 2.0, January 2004
To install Path::Iterator::Rule, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Path::Iterator::Rule
CPAN shell
perl -MCPAN -e shell install Path::Iterator::Rule
For more information on module installation, please visit the detailed CPAN module installation guide.