File-name encodings and unzip

Cameron Simpson cs at zip.com.au
Sun Mar 4 23:20:44 UTC 2007


On 04Mar2007 11:03, Colin Paul Adams <colin at colina.demon.co.uk> wrote:
| Thanks for that. I am using the default, I think. At least, I can see
| nothing locale-related in my environment other than:
| LANG=en_GB.UTF-8
| Shouldn't unzip be taking notice of this then?

Depends. Unzip may simply not care either - it may just be a byte string
to it.

Also, the unzip format may not record the source encoding; if you don't
know the source encoding you can't recode for the target system.

You may need to recode yourself. Several months ago I wrote a little python
program to recode MP3 filenames from UNIX (presuming a plain ISO8859-1
character set) into UTF-8 for HFS on a Mac (yeah, iTunes:-). Here:

  http://www.cskk.ezoshosting.com/cs/css/bin/macify

You might want to adapt it to your use.
-- 
Cameron Simpson <cs at zip.com.au> DoD#743
http://www.cskk.ezoshosting.com/cs/

Don't put off for tomorrow what you can do today.
If you enjoy it today, you can do it again tomorrow...




More information about the fedora-list mailing list