Thanks for your help, but I still have a few questions:

> If we drop the my `ls` trick above, we can use Perl's directory 
> handling calls:
> use Cwd;
> opendir DIR, getcwd() or die "Directory error:  $!\n";
> 
The code you gave me gives me errors when run:

readline() on unopened filehandle DIR at ./rename.pl line 12.
        (Are you trying to call readline() on dirhandle DIR?)

Do you happen to know what that means?

> First, $_ =~ /rename.pl/ is not a pattern match.  To test equality use 
> $_ eq 'rename.pl'.

Actually I want it to pattern match.  Emacs creates all sorts of files
like rename.pl~ and #rename.pl#.

-Dan


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to