Re: Malformed filenames

2005-03-03 Thread Michael Glaesemann
Resending, as I neglected to cc the list.

On Mar 3, 2005, at 21:08, Kino wrote:

> On 3 Mar 2005, at 20:48, Michael Glaesemann wrote:
>
>> I have a number of files that were created on Windows that have 
>> Japanese characters in the file name. The files were sent to me 
>> zipped. When the zip archive is uncompressed with English as the main 
>> language under Mac OS X, the filenames are malformed.
>
> I have no idea about a perlish way to correct them but you can try 
> some applications.
> 
> 
>
> As they are not new, they may not work on Panther.

Thanks for the quick response! I couldn't get the first to install, but 
Unifix looks promising.

ありがとうございました!

Michael Glaesemann
grzm myrealbox com

Re: Malformed filenames

2005-03-03 Thread Kino
On 3 Mar 2005, at 20:48, Michael Glaesemann wrote:
I have a number of files that were created on Windows that have 
Japanese characters in the file name. The files were sent to me 
zipped. When the zip archive is uncompressed with English as the main 
language under Mac OS X, the filenames are malformed.
I have no idea about a perlish way to correct them but you can try some 
applications.



As they are not new, they may not work on Panther.
Kino



Malformed filenames

2005-03-03 Thread Michael Glaesemann
Hello, all!
What I have is not a problem with perl on Mac OS X, but rather a 
problem on Mac OS X that I'd like to solve using perl. I'm not sure how 
to go about solving it, and am looking for suggestions.

I have a number of files that were created on Windows that have 
Japanese characters in the file name. The files were sent to me zipped. 
When the zip archive is uncompressed with English as the main language 
under Mac OS X, the filenames are malformed. (iirc, if Japanese is the 
main language, this isn't a problem, but it's been awhile since I've 
done that, and I wouldn't want to have to switch languages and relaunch 
the Finder every time I unzipped a file that might have Japanese in the 
filename.)

I'd like to make a perl script that would rename the files, but I'm not 
sure how to force reading the characters as a different encoding, nor 
sure which encoding I should use. I can handle a little trial and error 
with the last part (trying different encodings should be a simple 
matter of a foreach loop :), but am not sure how to approach the 
re-encoding part.

Hints, pointers, perldoc references much appreciated.
Michael Glaesemann
grzm myrealbox com