File and folder names containing "Ğ ğ – Ü ü – İ – ı – Ö ö – Ş ş" ?
SlackwareThis Forum is for the discussion of Slackware Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
USB sticks use FAT filesystem, so it should be possible. As for the other problem you mentioned, I didn't quite understand what it is. Are you saying that you can create new files with special characters but the preexisting files still show wrong? If so, were those files created using utf8 really? There's also the ISO-8859-9 encoding for the Turkish alphabet and I remember using that to mount my Windows vfat partitions some years ago (I think you also needed codepage=857 or something like that). I'm not sure but at least on recent Windows (or on ntfs) utf8 should be the locale.
Yes names of pre-existing files created on windows are still shown in destroyed form. I can rename them with the names consisting special characters. I can create and rename files and folders with charater i use, but i can not convert names of all problematic files into the right form. The only solution for me now is that renaming each file by hand.
Now i am going to copy one of these files, let us look what you see please.
Distribution: Slackware64 14.2 and current, SlackwareARM current
Posts: 1,644
Rep:
You could try convmv like I suggested above. I tested it only on linux partitions, but it should also work on windows partitions. You see any changes beforehand and can check if the script converts the characters right, so in the first run (with missing "--notest") convmv won't write anything but just do a dry run.
Distribution: Slackware64 14.2 and current, SlackwareARM current
Posts: 1,644
Rep:
I get Nilüfer - 08 - Ansìzìn.mp3, first word with u with dieresis (double points) in the middle, second word with two accents grave on i. I am using utf8 as my locale though (de_DE.utf8).
Hi sertmusluman, you have saved the files with an other locale than your current one. What does "locale" output as your current setting?
You can then use convmv http://www.j3e.de/linux/convmv/ to convert files to your current locale, but test it on a copy before you might break something.
Example (just call convmv without any option to see the help) to convert from iso8859-9 to utf8 encoding:
Code:
convmv -f iso8859-9 -t utf8 -r
If the testrun is ok, you call it with added "--notest" to actually apply the changes.
I could not install convmv tool and looked for a native slackware package of it bu i could not find.
Can i apply this process only one file to try?
Here "convmv -f iso8859-9 -t utf8 -r" command is for what? For whole content of current directory?
Distribution: Slackware64 14.2 and current, SlackwareARM current
Posts: 1,644
Rep:
No need to "install" it, it's just a perl script. Get the tarball, unpack it and mv the file whereever you want (if you want it in /usr/bin so copy it there or whereever.
And yes. you go (cd ..) where you want to try it (copy some files in a testfolder first), then convmv will work from there and down into subfolders - folders that are above in the folder structure won't get touched.
EDIT: make only sure it's executable (chmod +x convmv) or call it with "perl convmv", both ways are ok, the first one is more handy.
Last edited by titopoquito; 12-21-2008 at 05:50 AM.
I get Nilüfer - 08 - Ansìzìn.mp3, first word with u with dieresis (double points) in the middle, second word with two accents grave on i. I am using utf8 as my locale though (de_DE.utf8).
I can not get the output that you got.Did your Slack converted it into this form during extraction? If mine does this, this will be sufficent for me because now it is meaningful for me, but still wrong, "Ansizin" must be "Ansızın". In this word letter "ì" must be without head like "ı".
EDIT: Now I saw your last post. I am going to try.
Last edited by sertmusluman; 12-21-2008 at 05:57 AM.
Distribution: Slackware64 14.2 and current, SlackwareARM current
Posts: 1,644
Rep:
I guess it is saved in utf8, my system does that transparently, that means I just extract the file and it reads like that. The "i" is with accent grave (the accent from upper left to lower right), so definitely not the accent you want on your system.
sinem@sinemg:~$ su
Password:
root@sinemg:/home/sinem# cd /home/sinem/Desktop/convmv-1.01
root@sinemg:/home/sinem/Desktop/convmv-1.01# chmod -R a+x *
root@sinemg:/home/sinem/Desktop/convmv-1.01# convmv -f iso8859-9 -t utf8 -r
bash: convmv: command not found
root@sinemg:/home/sinem/Desktop/convmv-1.01# /home/sinem/Desktop/convmv-1.01 -f iso8859-9 -t utf8 -r
bash: /home/sinem/Desktop/convmv-1.01: is a directory
root@sinemg:/home/sinem/Desktop/convmv-1.01# /home/sinem/Desktop/convmv-1.01/convmv -f iso8859-9 -t utf8 -r
Unknown option: r
convmv 1.01 - converts filenames from one encoding to another
Copyright (C) 2003 Bjoern Jacke <bjoern@j3e.de>
This program comes with ABSOLUTELY NO WARRANTY; it may be copied or modified
under the terms of the GNU General Public License version 2 as published by
the Free Software Foundation.
USAGE: convmv [options] FILE(S)
-f enc encoding *from* which should to converted
-t enc encoding *to* which should to converted
-i interactive mode (ask for each action)
--nfc target files will be normalization form C for UTF-8 (Linux etc.)
--nfd target files will be normalization form D for UTF-8 (OS X etc.)
--qfrom be quiet about the "from" of a rename (if it screws up your terminal e.g.)
--qto be quiet about the "to" of a rename (if it screws up your terminal e.g.)
--list list all available encoding
--nosmart ignore if files already seem to be UTF-8 and convert is posible
--notest just print out to stdout what will be done
--replace will replace files if they are equal
--help print this help
root@sinemg:/home/sinem/Desktop/convmv-1.01# clear
root@sinemg:/home/sinem/Desktop/convmv-1.01# ls
Changes GPL2 MD5sums Makefile Nilüfer - 08 - Ansìzìn.mp3 VERSION convmv
root@sinemg:/home/sinem/Desktop/convmv-1.01# chmod -R a+x *
root@sinemg:/home/sinem/Desktop/convmv-1.01# /home/sinem/Desktop/convmv-1.01/convmv -f iso8859-9 -t utf8 -r
Unknown option: r
convmv 1.01 - converts filenames from one encoding to another
Copyright (C) 2003 Bjoern Jacke <bjoern@j3e.de>
This program comes with ABSOLUTELY NO WARRANTY; it may be copied or modified
under the terms of the GNU General Public License version 2 as published by
the Free Software Foundation.
USAGE: convmv [options] FILE(S)
-f enc encoding *from* which should to converted
-t enc encoding *to* which should to converted
-i interactive mode (ask for each action)
--nfc target files will be normalization form C for UTF-8 (Linux etc.)
--nfd target files will be normalization form D for UTF-8 (OS X etc.)
--qfrom be quiet about the "from" of a rename (if it screws up your terminal e.g.)
--qto be quiet about the "to" of a rename (if it screws up your terminal e.g.)
--list list all available encoding
--nosmart ignore if files already seem to be UTF-8 and convert is posible
--notest just print out to stdout what will be done
--replace will replace files if they are equal
--help print this help
root@sinemg:/home/sinem/Desktop/convmv-1.01#
I got the above message.
Last edited by sertmusluman; 12-25-2008 at 04:17 AM.
Distribution: Slackware64 14.2 and current, SlackwareARM current
Posts: 1,644
Rep:
You call it as root. Root user has the current directory not in path, so you must precede the command with "./". This would work though if you do it as normal user.
root@sinemg:/home/sinem/Desktop/convmv-1.01# exit
exit
sinem@sinemg:~$ cd /home/sinem/Desktop/convmv-1.01
sinem@sinemg:~/Desktop/convmv-1.01$ ./convmv -f iso8859-9 -t utf8 -r *
Unknown option: r
Skipping, already UTF-8: .//Nilüfer - 08 - Ansìzìn.mp3
No changes to your files done. Use --notest to finally rename the files.
sinem@sinemg:~/Desktop/convmv-1.01$
Distribution: Slackware64 14.2 and current, SlackwareARM current
Posts: 1,644
Rep:
First, I'm not sure if you have to use it the other way round (-f utf8 -t iso8859-9) since you use tr_TR locale and not tr_TR.utf8.
Second: You use a very old version of convmv. Get the latest version and it will understand the -r option. Furthermore you may break your special characters, newer versions work around some bugs in perl that else could lead to some funny characters. Version 1.14 is the current package.
Last edited by titopoquito; 12-21-2008 at 06:27 AM.
So it's already utf8 (and it says unknown option -r, as you can see, it's not in the list of options. Please make the basic research and checks before you post).
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.