On 12/08/2011 00:17, siegfr...@heintze.com wrote:
This works! Is there a way to do it with less typing? How can I do it without creating a temporary variable "@p"? Thanks, siegfriedfind /xyz -exec perl -e 'foreach(@ARGV){ my @p=split "/"; rename $_, "./$p[$#p].txt" } '
find /xyz -exec perl -e '/([^\/]+)\z/ and rename $_,"$1.txt" for @ARGV'; Rob -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/