Re: rename not working on files with accents in names

Chris Mattern wrote:

> Tom Bates wrote:
>> Thanks for reminding me about being able to see the actual error info
>> (I referred to the Perl help pages for the available error variables).
>> After the rename fails:
>> $! == "No such file or directory"
>> $^E == "The system cannot find the file specified"
>> $? == 0
>> I have many files with other accented characters that cause the same
>> problem, BTW. I'm just using this one to narrow down the problem.
> Please don't top-post. Put your reply after the text you are replying
> to. That said, I firmly believe that your problem is that your Perl
> program and Windows aren't using the same character set--that is,
> "á" in your Perl program and "á" on your command line aren't in fact
> the same character. As I very rarely need to fool with non-ASCII
> character sets, I'll leave your solutions to somebody who understands
> them better.

It occurs to me that there is a simple test for this. Have your
Perl program create "Tecatitlán.txt". Then look at the file
in Windows. If it has a weird character instead of "á", then
that's your problem.

Christopher Mattern

"Which one you figure tracked us?"
"The ugly one, sir."
"...Could you be more specific?"