Re: Accented chars in filenames issue
2011/6/24 Camaleón noela...@gmail.com On Fri, 24 Jun 2011 12:05:17 +0200, Raffaele Morelli wrote: I am experiencing serious problems with my external HD, I can't create/write filenames containing accented chars, especially when copying music from my amarok collection (as you can guess a lor of brazilian, french and italian music has plenty of accented chars in filenames). (...) For this kind of weird issues, what it usually helps is mounting the device manually (with mount command) and trying to write a file in there, also, from command line. Hopefully the error you get can shed some light on the problem. Greetings, -- Camaleón the device is being mounted correctly so no error is reported, but I still can't create/write filenames with accented chars. -r
Re: Accented chars in filenames issue
To give a silly example, a file named -rf * or rm -rf * lee l...@yun.yagibdah.de wrote: I defy you to create a file with those name ;-p touch './-rf *' The ./ prefix is the key to removing it afterwards, too. Chris -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/3uvld8x5q6@news.roaima.co.uk
Re: Accented chars in filenames issue
On Mon, 27 Jun 2011 10:53:55 +0200, Raffaele Morelli wrote: 2011/6/24 Camaleón noela...@gmail.com On Fri, 24 Jun 2011 12:05:17 +0200, Raffaele Morelli wrote: I am experiencing serious problems with my external HD, I can't create/write filenames containing accented chars, especially when copying music from my amarok collection (as you can guess a lor of brazilian, french and italian music has plenty of accented chars in filenames). (...) For this kind of weird issues, what it usually helps is mounting the device manually (with mount command) and trying to write a file in there, also, from command line. Hopefully the error you get can shed some light on the problem. the device is being mounted correctly so no error is reported, but I still can't create/write filenames with accented chars. Put here the output you get when you try to save a file with accented characters on its filename, but do it from command line, do not use GUI applications because sometimes, more than helping, quietly silence the underlaying problem. For instance: sm01@stt008:~$ echo sample áéíóú.txt sm01@stt008:~$ file áéíóú.txt áéíóú.txt: ASCII text sm01@stt008:~$ cat áéíóú.txt sample Greetings, -- Camaleón -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/pan.2011.06.27.11.19...@gmail.com
Re: Accented chars in filenames issue
Scott Ferguson prettyfly.producti...@gmail.com writes: On 27/06/11 00:55, William Hopkins wrote: On 06/26/11 at 09:45pm, Scott Ferguson wrote: On 26/06/11 19:25, Tom Furie wrote: On Sat, Jun 25, 2011 at 03:20:13PM +1000, Scott Ferguson wrote: On 25/06/11 10:16, lee wrote: snipped What does the -- do?? POSIX standard is for -- to signify end of options, so anything beyond that cannot be processed as a switch/option. ,--- | Guideline 10: | The first -- argument that is not an option-argument should be accepted as | a delimiter indicating the end of options. Any following arguments should be | treated as operands, even if they begin with the '-' character. ,--- Thanks -- should prove very useful (much simpler safety than other proposals). Also explains why it didn't throw an error. There's a difference between touch -- file* and touch file*, isn't there? The guideline also says should, not must. -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/871uyfo6p6@yun.yagibdah.de
Re: Accented chars in filenames issue
lee l...@yun.yagibdah.de wrote: There's a difference between touch -- file* and touch file*, isn't there? Yes there is, and you can see the difference when you have one or more files, in the current directory, whose names start with file. (Hint: precede or replace 'touch' with 'echo'.) Chris -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/quqmd8xa6f@news.roaima.co.uk
Re: Accented chars in filenames issue
On Sat, Jun 25, 2011 at 03:20:13PM +1000, Scott Ferguson wrote: On 25/06/11 10:16, lee wrote: To give a silly example, a file named -rf * or rm -rf * I defy you to create a file with those name ;-p NOTE: I've tried. No point in it just being an untested opinion. You can't have tried very hard then: 'touch -- -rf *'. It's only common sense not to create file names that are likely to yield unexpected results. Agreed - but *as it's not possible* my agreement is worthless. It also belies the point of UTF. See above. Cheers, Tom -- Man is the best computer we can put aboard a spacecraft ... and the only one that can be mass produced with unskilled labor. -- Wernher von Braun signature.asc Description: Digital signature
Re: Accented chars in filenames issue
On 26/06/11 09:17, William Hopkins wrote: On 06/25/11 at 04:33pm, Scott Ferguson wrote: snipped OK, so the files are being created, and your FS can handle the characters, but somehow the characters aren't being translated. So it's not an issue with your filesystem, it's an issue with the filesystem the original files are on. I assume that's NTFS? Can you try mounting it and moving a file with mv ? Unfortunately that happened several years ago with some elses portable drive - I only noticed the problem when moving the music collection from ext3 to ext4 - the system kept coming up with not found messages when attempting to move filenames which had ISOcharacter set accented characters. Fortunately I've managed to rename them using Picard and MusicBrainz - there's far too many to do by hand. This thread was created by someone else with a similar problem - so the solution might be more use to them. I'm curious as to how it happened so I can avoid it in the future though. Especially as I increasingly come across people using the old non-UTF character sets for files. What I should do is create some rules so that when I mount ntfs and fat volumes in the future the problem is avoided... any suggestions'd be appreciated. Cheers -- You know we armed Iraq. I wondered about that too, you know. During the Persian Gulf war, those intelligence reports would come out: Iraq: incredible weapons – incredible weapons. How do you know that? Uh, well … we looked at the receipts. But as soon as that check clears, we're goin' in. What time's the bank open? Eight? We're going in at nine. ~ Bill Hicks on the Gulf War -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/4e070d61.8010...@gmail.com
Re: Accented chars in filenames issue
On 26/06/11 19:25, Tom Furie wrote: On Sat, Jun 25, 2011 at 03:20:13PM +1000, Scott Ferguson wrote: On 25/06/11 10:16, lee wrote: snipped You can't have tried very hard then: 'touch -- -rf *'. snipped Cheers, Tom You are (also) correct. Turns out there's a number of ways to do that. What does the -- do?? Both:- $ touch -rf * and:- $ touch -- -rf * work - so -- doesn't appear to do anything, yet it produces no error. Strange - I'd expect an error at least. Cheers -- You know we armed Iraq. I wondered about that too, you know. During the Persian Gulf war, those intelligence reports would come out: Iraq: incredible weapons – incredible weapons. How do you know that? Uh, well … we looked at the receipts. But as soon as that check clears, we're goin' in. What time's the bank open? Eight? We're going in at nine. ~ Bill Hicks on the Gulf War -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/4e071bed.3050...@gmail.com
Re: Accented chars in filenames issue
On 06/26/11 at 09:45pm, Scott Ferguson wrote: On 26/06/11 19:25, Tom Furie wrote: On Sat, Jun 25, 2011 at 03:20:13PM +1000, Scott Ferguson wrote: On 25/06/11 10:16, lee wrote: snipped You can't have tried very hard then: 'touch -- -rf *'. snipped Cheers, Tom You are (also) correct. Turns out there's a number of ways to do that. What does the -- do?? POSIX standard is for -- to signify end of options, so anything beyond that cannot be processed as a switch/option. ,--- | Guideline 10: | The first -- argument that is not an option-argument should be accepted as | a delimiter indicating the end of options. Any following arguments should be | treated as operands, even if they begin with the '-' character. ,--- -- Liam signature.asc Description: Digital signature
Re: Accented chars in filenames issue
On 27/06/11 00:55, William Hopkins wrote: On 06/26/11 at 09:45pm, Scott Ferguson wrote: On 26/06/11 19:25, Tom Furie wrote: On Sat, Jun 25, 2011 at 03:20:13PM +1000, Scott Ferguson wrote: On 25/06/11 10:16, lee wrote: snipped What does the -- do?? POSIX standard is for -- to signify end of options, so anything beyond that cannot be processed as a switch/option. ,--- | Guideline 10: | The first -- argument that is not an option-argument should be accepted as | a delimiter indicating the end of options. Any following arguments should be | treated as operands, even if they begin with the '-' character. ,--- Thanks -- should prove very useful (much simpler safety than other proposals). Also explains why it didn't throw an error. I remember seeing it before (IRIX and AIX) but, um, don't think I'd ever bothered to asking why :-(. Cheers -- You know we armed Iraq. I wondered about that too, you know. During the Persian Gulf war, those intelligence reports would come out: Iraq: incredible weapons – incredible weapons. How do you know that? Uh, well … we looked at the receipts. But as soon as that check clears, we're goin' in. What time's the bank open? Eight? We're going in at nine. ~ Bill Hicks on the Gulf War -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/4e074c8e.5000...@gmail.com
Re: Accented chars in filenames issue
On 25/06/11 15:53, William Hopkins wrote: On 06/25/11 at 03:20pm, Scott Ferguson wrote: On 25/06/11 10:16, lee wrote: Scott Ferguson prettyfly.producti...@gmail.com writes: snipped To give a silly example, a file named -rf * or rm -rf * I defy you to create a file with those name ;-p NOTE: I've tried. No point in it just being an untested opinion. Why wouldn't you be able to? None of those are forbidden characters for filenames. , |liam@slimer:~/safe$ touch ./-rf\ * |liam@slimer:~/safe$ ls |-rf * `--- Good point! Clearly I did not spend enough time trying. I obviously hadn't considered the lengths some people will go to. :-) I'd only tried the following:- $ touch -rf * touch: failed to get attributes of `f': No such file or directory $ touch -rf * touch: failed to get attributes of `f *': No such file or directory After reading your post I tried using Dolphin to create a directory called -rf * (without ). It worked! I shall now write a letter to my MP demanding laws are passed against bad weather. :-D Cheers -- I'm tired of this back-slapping Isn't humanity neat? bullsh#t. We're a virus with shoes, okay? That's all we are. ~ Bill Hicks -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/4e057b8f.3030...@gmail.com
Re: Accented chars in filenames issue
On 25/06/11 15:56, William Hopkins wrote: On 06/25/11 at 03:36pm, Scott Ferguson wrote: On 25/06/11 11:27, Doug wrote: On 06/24/2011 08:16 PM, lee wrote: Scott Fergusonprettyfly.producti...@gmail.com writes: snipped Maybe you should reply to one of the troubleshooting responses instead of the philosophical ones, then :P Perhaps. :-) What happens when you try touch touch a file with a special character? I'm not sure what you mean? Any error message? Have you tried mounting with the encoding options as recommended elsewhere? I may have missed something in the threads - as I don't know how to apply those options to ext3. scott@work:~$ mount | grep /disk /dev/sdc1 on /media/disk type ext3 (rw,nosuid,nodev,uhelper=hal) scott@work:~$ ls /media/disk/Music/Various Artists/Amelie - Soundtrack 01 - J'Y Suis Jamias All?.mp3 08 - A Quai.mp3 15 - Soir de F?te.mp3 02 - Les Jours Tristes.mp309 - Le Moulin.mp3 16 - La Red?couverte.mp3 03 - La Valse d'Am?lie.mp310 - Pas Si Simple.mp3 17 - Sur le Fil.mp3 04 - Comptine d'Un Autre ?t?.mp3 11 - La Valse D'Am?lie.mp3 18 - Le Banquet.mp3 05 - La Noy?e.mp3 12 - La Valse des Vieux Os.mp3 19 - La Valse D'Am?lie.mp3 06 - L' Autre Valse d'Am?lie.mp3 13 - La Dispute.mp3 20 - La Valse des Monstres.mp3 07 - Guilty.mp3 14 - Si Tu N'?tais Pas L?.mp3 scott@work:~$ ls /media/disk/Music/Various Artists/Amelie - Soundtrack | grep 03 03 - La Valse d'Am�lie.mp3 scott@work:~$ locale -ma C en_AU.utf8 POSIX Cheers -- I'm tired of this back-slapping Isn't humanity neat? bullsh#t. We're a virus with shoes, okay? That's all we are. ~ Bill Hicks -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/4e05812f.4020...@gmail.com
Re: Accented chars in filenames issue
To give a silly example, a file named -rf * or rm -rf * I defy you to create a file with those name ;-p NOTE: I've tried. No point in it just being an untested opinion. $ echo test * bash: *: ambiguous redirect $ echo test \* $ ls * Desktop Downloads hdsp.1 Any idea how I can get rid of the file named *? :D Ralf -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/1308982975.16430.14.camel@debian
Re: Accented chars in filenames issue
On Sat, 2011-06-25 at 08:22 +0200, Ralf Mardorf wrote: To give a silly example, a file named -rf * or rm -rf * I defy you to create a file with those name ;-p NOTE: I've tried. No point in it just being an untested opinion. $ echo test * bash: *: ambiguous redirect $ echo test \* $ ls * Desktop Downloads hdsp.1 Any idea how I can get rid of the file named *? :D Ralf I deleted it using nautilus. What's the file's path for the GNOME wastebasket? -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/1308983530.16430.16.camel@debian
Re: Accented chars in filenames issue
On 25/06/11 15:56, William Hopkins wrote: On 06/25/11 at 03:36pm, Scott Ferguson wrote: On 25/06/11 11:27, Doug wrote: On 06/24/2011 08:16 PM, lee wrote: Scott Fergusonprettyfly.producti...@gmail.com writes: snipped What happens when you try touch touch a file with a special character? snipped My apologies - I've worked out what you meant (I hope) $xmodmap -e keysym Alt_L = Multi_key scott@work:~/spec$ touch è scott@work:~/spec$ ls è Works fine. The problem is not creating filenames with special characters - it's translating the existing ones (from MS files) into UTF. I have the same problem as the original poster - I'd like to find a way to retain the original accented characters - if indeed, they're not already lost. Cheers -- I'm tired of this back-slapping Isn't humanity neat? bullsh#t. We're a virus with shoes, okay? That's all we are. ~ Bill Hicks -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/4e0584ce.2010...@gmail.com
Re: Accented chars in filenames issue
On 25/06/11 16:22, Ralf Mardorf wrote: To give a silly example, a file named -rf * or rm -rf * I defy you to create a file with those name ;-p NOTE: I've tried. No point in it just being an untested opinion. $ echo test * bash: *: ambiguous redirect $ echo test \* $ ls * Desktop Downloads hdsp.1 Any idea how I can get rid of the file named *? :D Ralf Have you tried ?:- # rm * nul Sorry couldn't resist. :-D $ rm * Cheers -- I'm tired of this back-slapping Isn't humanity neat? bullsh#t. We're a virus with shoes, okay? That's all we are. ~ Bill Hicks -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/4e058551.6010...@gmail.com
Re: Accented chars in filenames issue
Hi, Ralf Mardorf wrote: $ echo test \* $ ls * Desktop Downloads hdsp.1 Any idea how I can get rid of the file named *? # touch \* \ # ls * # find . -type f -name \* -print0|xargs -0 rm # ls # touch \* \ # find . -type f -name \ -print0|xargs -0 rm # ls * # touch \* \ # ls * # find . -type f -name \ -print0|xargs -0 rm;ls * # find . -type f -name \* -print0|xargs -0 rm;ls Cheers -- Kind Regards AndrewM Andrew McGlashan Broadband Solutions now including VoIP -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/4e058af7.6020...@affinityvision.com.au
Re: Accented chars in filenames issue
On 25/06/11 17:15, Andrew McGlashan wrote: Hi, Ralf Mardorf wrote: $ echo test \* $ ls * Desktop Downloads hdsp.1 Any idea how I can get rid of the file named *? # touch \* \ # ls * # find . -type f -name \* -print0|xargs -0 rm # ls # touch \* \ # find . -type f -name \ -print0|xargs -0 rm # ls * # touch \* \ # ls * # find . -type f -name \ -print0|xargs -0 rm;ls * # find . -type f -name \* -print0|xargs -0 rm;ls Cheers Bigger hammer scott@work:~/spec$ touch * scott@work:~/spec$ ls -A * scott@work:~/spec$ rm `ls -A` rm: cannot remove `': No such file or directory scott@work:~/spec$ ls -a . .. Cheers -- I'm tired of this back-slapping Isn't humanity neat? bullsh#t. We're a virus with shoes, okay? That's all we are. ~ Bill Hicks -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/4e059255.6050...@gmail.com
Re: Accented chars in filenames issue
Scott Ferguson wrote: Bigger hammer scott@work:~/spec$ touch * scott@work:~/spec$ ls -A * scott@work:~/spec$ rm `ls -A` rm: cannot remove `': No such file or directory The first part * removed both files AND any other file that might have been in the directory. # touch \* \ # ls -A * # ls -A|xargs rm # ls No error there, smaller hammer ;-) And just to show that it doesn't clear other files # touch \* \ a b c # ls *a b c # ls -A \* \ * # ls -A \* \|xargs rm # ls a b c Just for fun, to also prove that the * is a problem with the other smaller hammer attempt: # touch \* \ a b c # ls *a b c # rm $(ls -A) rm: cannot remove `': No such file or directory rm: cannot remove `a': No such file or directory rm: cannot remove `b': No such file or directory rm: cannot remove `c': No such file or directory # ls Do I need to tell anybody that I *like* these types of problems?LOL Cheers -- Kind Regards AndrewM Andrew McGlashan Broadband Solutions now including VoIP -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/4e05abf2.1080...@affinityvision.com.au
Re: Accented chars in filenames issue
On 25/06/11 19:35, Andrew McGlashan wrote: Scott Ferguson wrote: snipped The first part * removed both files AND any other file that might have been in the directory. There, we'll have to disagree. Perhaps your shell handles ls differently. Also you are running as root, I'm not scott@work:~/spec$ ls -a . .. Look - nothing there kids :-) scott@work:~/spec$ touch * scott@work:~/spec$ ls -a . .. * Is now! (for my next trick I'll need a wealthy volunteer from the audience) # touch \* \ # ls -A * # ls -A|xargs rm # ls No error there, smaller hammer ;-) And just to show that it doesn't clear other files # touch \* \ a b c # ls *a b c # ls -A \* \ * # ls -A \* \|xargs rm # ls a b c Just for fun, to also prove that the * is a problem with the other Which is where you lose me. Problem? smaller hammer attempt: # touch \* \ a b c # ls *a b c # rm $(ls -A) rm: cannot remove `': No such file or directory rm: cannot remove `a': No such file or directory rm: cannot remove `b': No such file or directory rm: cannot remove `c': No such file or directory # ls Do I need to tell anybody that I *like* these types of problems?LOL Cheers Can't say I like these types of problems ... :-) scott@work:~/spec$ ls -a . .. scott@work:~/spec$ touch * a b c scott@work:~/spec$ ls -al total 16 drwxr-xr-x 2 scott scott 4096 Jun 25 20:10 . drwxr-xr-x 72 scott scott 12288 Jun 25 18:57 .. -rw-r--r-- 1 scott scott 0 Jun 25 20:10 * -rw-r--r-- 1 scott scott 0 Jun 25 20:10 -rw-r--r-- 1 scott scott 0 Jun 25 20:10 a -rw-r--r-- 1 scott scott 0 Jun 25 20:10 b -rw-r--r-- 1 scott scott 0 Jun 25 20:10 c scott@work:~/spec$ rm * scott@work:~/spec$ ls -a . .. Another way to make nice slippers from a feline:- scott@work:~/spec$ touch * \ a 'b' c My preferred solution (apart from *not* doing this sort of thing as root):- $ touch \* \ a b c $ rm * The proof of the pud ;-p Cheers -- I'm tired of this back-slapping Isn't humanity neat? bullsh#t. We're a virus with shoes, okay? That's all we are. ~ Bill Hicks -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/4e05b6bf.9010...@gmail.com
Re: Accented chars in filenames issue
Hi, Scott Ferguson wrote: There, we'll have to disagree. Perhaps your shell handles ls differently. Also you are running as root, I'm not Yes, well as root, I admit -- quick tests in a special and safe working directory. /bin/bash shell Whatever you do use * do so with extreme caution, especially with rm. Test first to be sure if you wish to use it. And to stop command history being a problem, I often use the full path the files/directories such as: rm /tmp/somedir/* /tmp/somedir/.* Anyway, I'm sure everyone gets the message and no-one is thinking of using rm -rf * too easily or too quickly. And again, yes, doing anything like this as root needs even more care. The find with print0 and xargs with -0 are good tips for anyone too. Quite handy without having to worry about IFS as well on files and/or directories with other characters, like space(s). Cheers A. -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/4e05c413.7090...@affinityvision.com.au
Re: Accented chars in filenames issue
On 25/06/11 21:18, Andrew McGlashan wrote: Hi, Scott Ferguson wrote: snipped And to stop command history being a problem, I often use the full path the files/directories such as: rm /tmp/somedir/* /tmp/somedir/.* Good point. I shall run with scissor no more. snipped Cheers A. Cheers -- I'm tired of this back-slapping Isn't humanity neat? bullsh#t. We're a virus with shoes, okay? That's all we are. ~ Bill Hicks -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/4e05ce9e.5030...@gmail.com
Re: Accented chars in filenames issue
Scott Ferguson prettyfly.producti...@gmail.com writes: On 25/06/11 15:56, William Hopkins wrote: On 06/25/11 at 03:36pm, Scott Ferguson wrote: [...] Any error message? Have you tried mounting with the encoding options as recommended elsewhere? I may have missed something in the threads - as I don't know how to apply those options to ext3. Another advise: Avoid to use special mount options for mounting file systems as much as you can. If you can't avoid it, make sure that with the mount options you want to use, there isn't the possibility of losing data when different mount options happen to be used. If the possibility exists, do not use the mount options you want to use. -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/87mxh62flu@yun.yagibdah.de
Re: Accented chars in filenames issue
Scott Ferguson prettyfly.producti...@gmail.com writes: On 25/06/11 10:16, lee wrote: Scott Ferguson prettyfly.producti...@gmail.com writes: I don't think the no white spaces and no accented characters rule is valid in the 21st century. But if some one can put up an authoritative, and recent, reason I'll reconsider. Since (unfortunately) there isn't anything preventing users from creating files with names that contain special characters or spaces, you could say that there isn't such a rule anymore. There is... Where? :) Nonetheless I advise against it, very un-authoritatively of course, because it can be troublesome to create files with special characters or spaces in their names. To give a silly example, a file named -rf * or rm -rf * I defy you to create a file with those name ;-p NOTE: I've tried. No point in it just being an untested opinion. You can just rename a file with: # mv 1307474391 rm -rf * , | lee@yun:~/tmp/naming$ ls -la | insgesamt 52 | drwxr-xr-x 2 lee lee 4096 25. Jun 15:48 . | drwx-- 12 lee lee 32768 25. Jun 15:48 .. | -rw-r--r-- 1 lee lee 116 9. Jun 16:35 -rf | -rw-r--r-- 1 lee lee94 7. Jun 21:19 rm -rf * | -rw-r--r-- 1 lee lee94 7. Jun 21:17 rm -rf \* | -rw-r--r-- 1 lee lee94 7. Jun 21:16 rm -rf 1307474137 | lee@yun:~/tmp/naming$ ` I haven't tried touch, it'll probably work the same. A nice application might be to provide rm -rf * as a filename for an attachment to an email? Now how to remove these files gives me something to think about very carefully ... :( could turn out to be disastrous. Using other special characters, for example ä, ü, ö, and ß, can give you trouble when locale settings change and may have effects that I'm even not aware of. It's only common sense not to create file names that are likely to yield unexpected results. Agreed - but *as it's not possible* my agreement is worthless. It also belies the point of UTF. See above, there's no problem in creating files named rm -rf *. That makes me think that system administrators should have a way of specifying for each file system and globally which characters they allow in file names and which ones not. Should I send a feature request on the kernel package? -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/87ipru2eue@yun.yagibdah.de
Re: Accented chars in filenames issue
On 25/06/11 23:57, lee wrote: Scott Ferguson prettyfly.producti...@gmail.com writes: On 25/06/11 10:16, lee wrote: Scott Ferguson prettyfly.producti...@gmail.com writes: snipped Should I send a feature request on the kernel package? Not necessary - the subject has been adequately covered in many posts between the original and this one. Cheers -- I'm tired of this back-slapping Isn't humanity neat? bullsh#t. We're a virus with shoes, okay? That's all we are. ~ Bill Hicks -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/4e05f031.6010...@gmail.com
Re: Accented chars in filenames issue
lee l...@yun.yagibdah.de writes: You can just rename a file with: # mv 1307474391 rm -rf * , | lee@yun:~/tmp/naming$ ls -la | insgesamt 52 | drwxr-xr-x 2 lee lee 4096 25. Jun 15:48 . | drwx-- 12 lee lee 32768 25. Jun 15:48 .. | -rw-r--r-- 1 lee lee 116 9. Jun 16:35 -rf | -rw-r--r-- 1 lee lee94 7. Jun 21:19 rm -rf * | -rw-r--r-- 1 lee lee94 7. Jun 21:17 rm -rf \* | -rw-r--r-- 1 lee lee94 7. Jun 21:16 rm -rf 1307474137 | lee@yun:~/tmp/naming$ ` I haven't tried touch, it'll probably work the same. A nice application might be to provide rm -rf * as a filename for an attachment to an email? Now how to remove these files gives me something to think about very carefully ... :( [cut from here] #include stdio.h #include unistd.h #include errno.h #include error.h // the name of the file to be removed: #define NAME none int main(int argc, char *argv[] ) { int ret; int err; ret = unlink(NAME); err = errno; if(ret) { error(0, err, unlinking '%s', NAME); } else { printf('%s' successfully unlinked\n, NAME); } return ret; } [cut to here] Save it as removing.c, adjust the name of the file you want to remove and run gcc -Wall -Os -o removing removing.c. Than run ./removing to remove the file. -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/87ei2i2czm@yun.yagibdah.de
Re: Accented chars in filenames issue
On 06/25/2011 11:37 AM, lee wrote: lee l...@yun.yagibdah.de writes: , | lee@yun:~/tmp/naming$ ls -la | insgesamt 52 | drwxr-xr-x 2 lee lee 4096 25. Jun 15:48 . | drwx-- 12 lee lee 32768 25. Jun 15:48 .. | -rw-r--r-- 1 lee lee 116 9. Jun 16:35 -rf | -rw-r--r-- 1 lee lee94 7. Jun 21:19 rm -rf * | -rw-r--r-- 1 lee lee94 7. Jun 21:17 rm -rf \* | -rw-r--r-- 1 lee lee94 7. Jun 21:16 rm -rf 1307474137 | lee@yun:~/tmp/naming$ ` I haven't tried touch, it'll probably work the same. A nice application might be to provide rm -rf * as a filename for an attachment to an email? Now how to remove these files gives me something to think about very carefully ... :( [cut from here] #include stdio.h #include unistd.h #include errno.h #include error.h // the name of the file to be removed: #define NAME none int main(int argc, char *argv[] ) { int ret; int err; ret = unlink(NAME); err = errno; if(ret) { error(0, err, unlinking '%s', NAME); } else { printf('%s' successfully unlinked\n, NAME); } return ret; } [cut to here] Save it as removing.c, adjust the name of the file you want to remove and run gcc -Wall -Os -o removing removing.c. Than run ./removing to remove the file. Why all the touble? $ rm 'rm -rf *' does the job. Or use a file manager. -- If Robert Di Niro assassinates Walter Slezak, will Jodie Foster marry Bonzo?? Eduardo M KALINOWSKI edua...@kalinowski.com.br -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/4e05f367.7020...@kalinowski.com.br
Re: Accented chars in filenames issue
Ralf Mardorf ralf.mard...@alice-dsl.net writes: $ echo test \* $ ls * Desktop Downloads hdsp.1 Any idea how I can get rid of the file named *? Exactly the same way you created it. With a backslash. $ rm \* -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/5d92.4e05f078.14...@getafix.xdna.net
Re: Accented chars in filenames issue
Eduardo M KALINOWSKI edua...@kalinowski.com.br writes: Why all the touble? $ rm 'rm -rf *' does the job. Or use a file manager. Because I don't trust rm or a file manager to do it right and without unwanted side effects. -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/87oc1l24ni@yun.yagibdah.de
Re: Accented chars in filenames issue
On 06/25/11 at 04:33pm, Scott Ferguson wrote: scott@work:~$ mount | grep /disk /dev/sdc1 on /media/disk type ext3 (rw,nosuid,nodev,uhelper=hal) Looks fine.. scott@work:~$ ls /media/disk/Music/Various Artists/Amelie - Soundtrack 01 - J'Y Suis Jamias All?.mp3 08 - A Quai.mp3 15 - Soir de F?te.mp3 02 - Les Jours Tristes.mp309 - Le Moulin.mp3 16 - La Red?couverte.mp3 03 - La Valse d'Am?lie.mp310 - Pas Si Simple.mp3 17 - Sur le Fil.mp3 04 - Comptine d'Un Autre ?t?.mp3 11 - La Valse D'Am?lie.mp3 18 - Le Banquet.mp3 05 - La Noy?e.mp3 12 - La Valse des Vieux Os.mp3 19 - La Valse D'Am?lie.mp3 06 - L' Autre Valse d'Am?lie.mp3 13 - La Dispute.mp3 20 - La Valse des Monstres.mp3 07 - Guilty.mp3 14 - Si Tu N'?tais Pas L?.mp3 OK, so the files are being created, and your FS can handle the characters, but somehow the characters aren't being translated. So it's not an issue with your filesystem, it's an issue with the filesystem the original files are on. I assume that's NTFS? Can you try mounting it and moving a file with mv ? scott@work:~$ locale -ma C en_AU.utf8 POSIX Also looks fine. I have the same (except en_US). -- Liam signature.asc Description: Digital signature
Re: Accented chars in filenames issue
On 06/25/11 at 07:37pm, lee wrote: Eduardo M KALINOWSKI edua...@kalinowski.com.br writes: Why all the touble? $ rm 'rm -rf *' does the job. Or use a file manager. Because I don't trust rm or a file manager to do it right and without unwanted side effects. You should be able to trust rm, at least. Just add -i if you're paranoid. -- Liam signature.asc Description: Digital signature
Re: Accented chars in filenames issue
On 26/06/11 00:37, lee wrote: lee l...@yun.yagibdah.de writes: snipped Save it as removing.c, adjust the name of the file you want to remove and run gcc -Wall -Os -o removing removing.c. Than run ./removing to remove the file. ++1 LMAO :-D Now *that* is a bigger hammer! Cheers -- You know we armed Iraq. I wondered about that too, you know. During the Persian Gulf war, those intelligence reports would come out: Iraq: incredible weapons – incredible weapons. How do you know that? Uh, well … we looked at the receipts. But as soon as that check clears, we're goin' in. What time's the bank open? Eight? We're going in at nine. ~ Bill Hicks on the Gulf War -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/4e06995c.4020...@gmail.com
Re: Accented chars in filenames issue
William Hopkins wrote: You should be able to trust rm, at least. Just add -i if you're paranoid. And if you are more paranoid, fully path rm to ensure no alias is changing anything. # which rm /bin/rm -- Kind Regards AndrewM -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/4e069ea0.1090...@affinityvision.com.au
Re: Accented chars in filenames issue
Andrew McGlashan andrew.mcglas...@affinityvision.com.au writes: William Hopkins wrote: You should be able to trust rm, at least. Just add -i if you're paranoid. And if you are more paranoid, fully path rm to ensure no alias is changing anything. There are at least three things involved: rm, the shell and the user. If the shell would do some unexpected extensions, I might get unexpected results: that's the reason why the file name is defined in the program and not handed over on the commandline. Both the shell and rm are probably fine and work as they are supposed to. The user may easily overlook something. It wasn't something I could have tried out in advance very well, and writing the program took only a few minutes. Better save than sorry ... -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/8762ntywxu@yun.yagibdah.de
Re: Accented chars in filenames issue
On Vi, 24 iun 11, 12:05:17, Raffaele Morelli wrote: Hi, I am experiencing serious problems with my external HD, I can't create/write filenames containing accented chars, especially when copying music from my amarok collection (as you can guess a lor of brazilian, french and italian music has plenty of accented chars in filenames). Is it a locale problem? I have got all locales installed, my default is it_IT@euro. Tried with utf8 and others with no success. Please specify *at least*: - kernel version (uname -a) - mount helper used or mount options - the output of 'cat /proc/mounts' after mounting the drive - the output of 'locale' Regards, Andrei -- Offtopic discussions among Debian users and developers: http://lists.alioth.debian.org/mailman/listinfo/d-community-offtopic signature.asc Description: Digital signature
Re: Accented chars in filenames issue
2011/6/24 Lorenzo Sutton lsut...@libero.it Raffaele Morelli wrote: Hi, I am experiencing serious problems with my external HD, I can't create/write filenames containing accented chars, especially when copying music from my amarok collection (as you can guess a lor of brazilian, french and italian music has plenty of accented chars in filenames). What filesystem is the external HD? Tried both with ext3 (first) and fat32 (now) Is it a locale problem? I have got all locales installed, my default is it_IT@euro. Tried with utf8 and others with no success. Did you also try experimenting with the utf8 and charset options when mounting the drive? no, I've always mounted the drive using dolphin Lorenzo. forgot to say I am on debian testing, kernel 2.6.39.1 (PREEMPT) regards
Re: Accented chars in filenames issue
Raffaele Morelli wrote: Hi, I am experiencing serious problems with my external HD, I can't create/write filenames containing accented chars, especially when copying music from my amarok collection (as you can guess a lor of brazilian, french and italian music has plenty of accented chars in filenames). What filesystem is the external HD? Is it a locale problem? I have got all locales installed, my default is it_IT@euro. Tried with utf8 and others with no success. Did you also try experimenting with the utf8 and charset options when mounting the drive? Lorenzo. Any suggestion is appreciated. Regards Raffaele -- /L'unica speranza di catarsi, ammesso che ne esista una, resta affidata all'istinto di ribellione, alla rivolta non isterilita in progetti, alla protesta violenta e viscerale./ -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/4e0463f0.7020...@libero.it
Re: Accented chars in filenames issue
2011/6/24 Andrei POPESCU andreimpope...@gmail.com On Vi, 24 iun 11, 12:05:17, Raffaele Morelli wrote: Hi, I am experiencing serious problems with my external HD, I can't create/write filenames containing accented chars, especially when copying music from my amarok collection (as you can guess a lor of brazilian, french and italian music has plenty of accented chars in filenames). Is it a locale problem? I have got all locales installed, my default is it_IT@euro. Tried with utf8 and others with no success. Please specify *at least*: - kernel version (uname -a) Linux jimi 2.6.39.1-ra #1 SMP PREEMPT Thu Jun 9 20:34:53 CEST 2011 x86_64 GNU/Linux - mount helper used or mount options dolphin, KDE4 - the output of 'cat /proc/mounts' after mounting the drive cassiel@jimi:~$ cat /proc/mounts rootfs / rootfs rw 0 0 sysfs /sys sysfs rw,nosuid,nodev,noexec,relatime 0 0 proc /proc proc rw,nosuid,nodev,noexec,relatime 0 0 udev /dev devtmpfs rw,relatime,size=1542336k,nr_inodes=385584,mode=755 0 0 devpts /dev/pts devpts rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000 0 0 tmpfs /run tmpfs rw,nosuid,noexec,relatime,size=309424k,mode=755 0 0 /dev/disk/by-uuid/63406ae8-3762-4c22-ad27-6201e3b54c39 / ext3 rw,relatime,errors=remount-ro,commit=5,barrier=0,data=ordered 0 0 tmpfs /lib/init/rw tmpfs rw,nosuid,relatime,size=5120k,mode=755 0 0 tmpfs /run/shm tmpfs rw,nosuid,nodev,relatime,size=618848k 0 0 /dev/sda7 /home ext3 rw,relatime,errors=continue,commit=5,barrier=0,data=ordered 0 0 fusectl /sys/fs/fuse/connections fusectl rw,relatime 0 0 binfmt_misc /proc/sys/fs/binfmt_misc binfmt_misc rw,nosuid,nodev,noexec,relatime 0 0 /dev/sdb2 /media/AMB-AGF1 vfat rw,nosuid,nodev,relatime,uid=1000,gid=1001,fmask=0022,dmask=0077,codepage=cp437,iocharset=utf8,shortname=mixed,showexec,utf8,errors=remount-ro 0 0 - the output of 'locale' cassiel@jimi:~$ locale LANG=it_IT@euro LANGUAGE= LC_CTYPE=it_IT@euro LC_NUMERIC=it_IT@euro LC_TIME=it_IT@euro LC_COLLATE=it_IT@euro LC_MONETARY=it_IT@euro LC_MESSAGES=it_IT@euro LC_PAPER=it_IT@euro LC_NAME=it_IT@euro LC_ADDRESS=it_IT@euro LC_TELEPHONE=it_IT@euro LC_MEASUREMENT=it_IT@euro LC_IDENTIFICATION=it_IT@euro LC_ALL= Regards, Andrei -r
Re: Accented chars in filenames issue
Raffaele Morelli raffaele.more...@gmail.com writes: I am experiencing serious problems with my external HD, I can't create/write filenames containing accented chars, especially when copying music from my amarok collection (as you can guess a lor of brazilian, french and italian music has plenty of accented chars in filenames). It's a very bad idea to use special characters (or spaces) in file names. You can get it to work, and it may cause trouble when your locale settings change or when you try to use the files on other computers. You're already experiencing such trouble, so why make it difficult? -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/87k4cbjyio@yun.yagibdah.de
Re: Accented chars in filenames issue
2011/6/24 lee l...@yun.yagibdah.de Raffaele Morelli raffaele.more...@gmail.com writes: I am experiencing serious problems with my external HD, I can't create/write filenames containing accented chars, especially when copying music from my amarok collection (as you can guess a lor of brazilian, french and italian music has plenty of accented chars in filenames). It's a very bad idea to use special characters (or spaces) in file names. You can get it to work, and it may cause trouble when your locale settings change or when you try to use the files on other computers. You're already experiencing such trouble, so why make it difficult? well, I never use whitespaces and accented chars when working on linux, but... when your music collection it's about 32.027 tracks (I am a guitar player and music lover) it's difficult to get rid of accented chars :-) (should I drop baden powell? joao gilberto?...) BTW replacing accented chars using some one-line program could do you more harm than ever -r
Re: Accented chars in filenames issue
On Fri, 24 Jun 2011 12:05:17 +0200, Raffaele Morelli wrote: I am experiencing serious problems with my external HD, I can't create/write filenames containing accented chars, especially when copying music from my amarok collection (as you can guess a lor of brazilian, french and italian music has plenty of accented chars in filenames). (...) For this kind of weird issues, what it usually helps is mounting the device manually (with mount command) and trying to write a file in there, also, from command line. Hopefully the error you get can shed some light on the problem. Greetings, -- Camaleón -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/pan.2011.06.24.13.51...@gmail.com
Re: Accented chars in filenames issue
Raffaele Morelli raffaele.more...@gmail.com writes: 2011/6/24 lee l...@yun.yagibdah.de Raffaele Morelli raffaele.more...@gmail.com writes: I am experiencing serious problems with my external HD, I can't create/write filenames containing accented chars, especially when copying music from my amarok collection (as you can guess a lor of brazilian, french and italian music has plenty of accented chars in filenames). It's a very bad idea to use special characters (or spaces) in file names. well, I never use whitespaces and accented chars when working on linux, but... when your music collection it's about 32.027 tracks (I am a guitar player and music lover) it's difficult to get rid of accented chars :-) (should I drop baden powell? joao gilberto?...) Just don't introduce them in the first place. Why would you have to remove some files? BTW replacing accented chars using some one-line program could do you more harm than ever Does it matter how many lines such a program has? -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/87ei2j494n@yun.yagibdah.de
Re: Accented chars in filenames issue
On Fri, 24 Jun 2011 13:51:11 + (UTC) Camaleón noela...@gmail.com wrote: On Fri, 24 Jun 2011 12:05:17 +0200, Raffaele Morelli wrote: I am experiencing serious problems with my external HD, I can't create/write filenames containing accented chars, especially when copying music from my amarok collection (as you can guess a lor of brazilian, french and italian music has plenty of accented chars in filenames). (...) For this kind of weird issues, what it usually helps is mounting the device manually (with mount command) and trying to write a file in there, also, from command line. Hopefully the error you get can shed some light on the problem. Also is it possible that the characters are in the filename but they are not being displayed ? I have US locale set to en_US.UTF-8 and accented characters work in filenames. Brian -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/20110624075035.07467...@windy.deldotd.com
Re: Accented chars in filenames issue
On 24/06/11 20:05, Raffaele Morelli wrote: Hi, I am experiencing serious problems with my external HD, I can't create/write filenames containing accented chars, especially when copying music from my amarok collection (as you can guess a lor of brazilian, french and italian music has plenty of accented chars in filenames). Is it a locale problem? I have got all locales installed, my default is it_IT@euro. Tried with utf8 and others with no success. Any suggestion is appreciated. Regards Raffaele I'm looking for a solution to the same problem. You might find this page instructive:- http://www.cl.cam.ac.uk/~mgk25/unicode.html My system is set to LANG=en_AU.UTF-8, filesystems ext3 and ext4, I suspect the file names where originally created using an ISO character set. See an example:- http://lists.debian.org/debian-user/2011/06/pngTe0u43cmOF.png I don't think the no white spaces and no accented characters rule is valid in the 21st century. But if some one can put up an authoritative, and recent, reason I'll reconsider. Cheers -- I'm tired of this back-slapping Isn't humanity neat? bullsh#t. We're a virus with shoes, okay? That's all we are. ~ Bill Hicks -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/4e04ae9e.6020...@gmail.com
Re: Accented chars in filenames issue
On Sat, Jun 25, 2011 at 01:34:54AM +1000, Scott Ferguson wrote: [...] I don't think the no white spaces and no accented characters rule is valid in the 21st century. But if some one can put up an authoritative, and recent, reason I'll reconsider. You won't get anything authoritative from me, but I have noticed traps for the unwary, for example: $ mkdir newdir; cd newdir $ touch 'one space' 'and two spaces' $ for jim in *; do echo $jim; done and two spaces one space So far, so good, but: $ for jim in `ls`; do echo $jim; done and two spaces one space which is not what was intended. Cheers, David -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/20110624220549.GB3067@gennes.augarten
Re: Accented chars in filenames issue
Scott Ferguson prettyfly.producti...@gmail.com writes: I don't think the no white spaces and no accented characters rule is valid in the 21st century. But if some one can put up an authoritative, and recent, reason I'll reconsider. Since (unfortunately) there isn't anything preventing users from creating files with names that contain special characters or spaces, you could say that there isn't such a rule anymore. Nonetheless I advise against it, very un-authoritatively of course, because it can be troublesome to create files with special characters or spaces in their names. To give a silly example, a file named -rf * or rm -rf * could turn out to be disastrous. Using other special characters, for example ä, ü, ö, and ß, can give you trouble when locale settings change and may have effects that I'm even not aware of. It's only common sense not to create file names that are likely to yield unexpected results. -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/87mxh6epf0@yun.yagibdah.de
Re: Accented chars in filenames issue
On 06/24/2011 08:16 PM, lee wrote: Scott Fergusonprettyfly.producti...@gmail.com writes: I don't think the no white spaces and no accented characters rule is valid in the 21st century. But if some one can put up an authoritative, and recent, reason I'll reconsider. Since (unfortunately) there isn't anything preventing users from creating files with names that contain special characters or spaces, you could say that there isn't such a rule anymore. Nonetheless I advise against it, very un-authoritatively of course, because it can be troublesome to create files with special characters or spaces in their names. To give a silly example, a file named -rf * or rm -rf * could turn out to be disastrous. Using other special characters, for example ä, ü, ö, and ß, can give you trouble when locale settings change and may have effects that I'm even not aware of. It's only common sense not to create file names that are likely to yield unexpected results. Probably the best reason is if you *ever* share files, or send one to someone else, he/she is as likely as not not to have the capability of inputting the accented character. --doug -- Blessed are the peacekeepers...for they shall be shot at from both sides. --A. M. Greeley -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/4e053985.8050...@optonline.net
Re: Accented chars in filenames issue
On 25/06/11 08:05, David Jardine wrote: $ mkdir newdir; cd newdir $ touch 'one space' 'and two spaces' $ for jim in *; do echo $jim; done and two spaces one space So far, so good, but: $ for jim in `ls`; do echo $jim; done and two spaces one space I don't understand why you'd use that method. If you do need to use that approach $jim might be better (for other uses). Try:- $ ls -Q and two spaces one space Or if the long route is required :- $ ls -1Q | while read jim; do echo $jim ; done and two spaces one space Cheers -- I'm tired of this back-slapping Isn't humanity neat? bullsh#t. We're a virus with shoes, okay? That's all we are. ~ Bill Hicks -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/4e056ded.8030...@gmail.com
Re: Accented chars in filenames issue
On 25/06/11 08:05, David Jardine wrote: On Sat, Jun 25, 2011 at 01:34:54AM +1000, Scott Ferguson wrote: [...] I don't think the no white spaces and no accented characters rule is valid in the 21st century. But if some one can put up an authoritative, and recent, reason I'll reconsider. You won't get anything authoritative from me, but I have noticed traps for the unwary, for example: $ mkdir newdir; cd newdir $ touch 'one space' 'and two spaces' $ for jim in *; do echo $jim; done and two spaces one space So far, so good, but: $ for jim in `ls`; do echo $jim; done and two spaces one space which is not what was intended. Cheers, David man bash /IFS ??? Cheers -- I'm tired of this back-slapping Isn't humanity neat? bullsh#t. We're a virus with shoes, okay? That's all we are. ~ Bill Hicks -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/4e056e79.2010...@gmail.com
Re: Accented chars in filenames issue
On 25/06/11 10:16, lee wrote: Scott Ferguson prettyfly.producti...@gmail.com writes: I don't think the no white spaces and no accented characters rule is valid in the 21st century. But if some one can put up an authoritative, and recent, reason I'll reconsider. Since (unfortunately) there isn't anything preventing users from creating files with names that contain special characters or spaces, you could say that there isn't such a rule anymore. There is... Nonetheless I advise against it, very un-authoritatively of course, because it can be troublesome to create files with special characters or spaces in their names. To give a silly example, a file named -rf * or rm -rf * I defy you to create a file with those name ;-p NOTE: I've tried. No point in it just being an untested opinion. could turn out to be disastrous. Using other special characters, for example ä, ü, ö, and ß, can give you trouble when locale settings change and may have effects that I'm even not aware of. It's only common sense not to create file names that are likely to yield unexpected results. Agreed - but *as it's not possible* my agreement is worthless. It also belies the point of UTF. Cheers -- I'm tired of this back-slapping Isn't humanity neat? bullsh#t. We're a virus with shoes, okay? That's all we are. ~ Bill Hicks -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/4e05700d.3030...@gmail.com
Re: Accented chars in filenames issue
On 25/06/11 11:27, Doug wrote: On 06/24/2011 08:16 PM, lee wrote: Scott Fergusonprettyfly.producti...@gmail.com writes: snipped Probably the best reason is if you *ever* share files, or send one to someone else, he/she is as likely as not not to have the capability of inputting the accented character. --doug In this case it would require educating Microsoft Windows users (and corrupting my nicely organised and extensive music collection). Which is where the problem came from. I have no problems with either ext3 or ext4 in creating filenames with whitespaces and accented characters. Note the screen shot:- http://lists.debian.org/debian-user/2011/06/pngTe0u43cmOF.png - that's a file being transferred from a MS users NTFS drive to mine - I can play the file fine (on their drive) but it won't copy across unless I create a non-UTF file system, or rename it. Dumbing down all song, album, and artist names to remove whitespaces and accented characters is not feasible. There's a difference between Camaleon and Camaleón, and it's a difference Amarok has no trouble with. The whole point of UTF is to be able to deal with extended character sets. Cheers -- I'm tired of this back-slapping Isn't humanity neat? bullsh#t. We're a virus with shoes, okay? That's all we are. ~ Bill Hicks -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/4e0573f0.40...@gmail.com
Re: Accented chars in filenames issue
On 06/25/11 at 03:20pm, Scott Ferguson wrote: On 25/06/11 10:16, lee wrote: Scott Ferguson prettyfly.producti...@gmail.com writes: I don't think the no white spaces and no accented characters rule is valid in the 21st century. But if some one can put up an authoritative, and recent, reason I'll reconsider. Since (unfortunately) there isn't anything preventing users from creating files with names that contain special characters or spaces, you could say that there isn't such a rule anymore. There is... Nonetheless I advise against it, very un-authoritatively of course, because it can be troublesome to create files with special characters or spaces in their names. To give a silly example, a file named -rf * or rm -rf * I defy you to create a file with those name ;-p NOTE: I've tried. No point in it just being an untested opinion. Why wouldn't you be able to? None of those are forbidden characters for filenames. , |liam@slimer:~/safe$ touch ./-rf\ * |liam@slimer:~/safe$ ls |-rf * `--- -- Liam signature.asc Description: Digital signature
Re: Accented chars in filenames issue
On 06/25/11 at 03:36pm, Scott Ferguson wrote: On 25/06/11 11:27, Doug wrote: On 06/24/2011 08:16 PM, lee wrote: Scott Fergusonprettyfly.producti...@gmail.com writes: snipped Probably the best reason is if you *ever* share files, or send one to someone else, he/she is as likely as not not to have the capability of inputting the accented character. --doug In this case it would require educating Microsoft Windows users (and corrupting my nicely organised and extensive music collection). Which is where the problem came from. I have no problems with either ext3 or ext4 in creating filenames with whitespaces and accented characters. Note the screen shot:- http://lists.debian.org/debian-user/2011/06/pngTe0u43cmOF.png - that's a file being transferred from a MS users NTFS drive to mine - I can play the file fine (on their drive) but it won't copy across unless I create a non-UTF file system, or rename it. Dumbing down all song, album, and artist names to remove whitespaces and accented characters is not feasible. There's a difference between Camaleon and Camaleón, and it's a difference Amarok has no trouble with. The whole point of UTF is to be able to deal with extended character sets. Maybe you should reply to one of the troubleshooting responses instead of the philosophical ones, then :P What happens when you try touch touch a file with a special character? Any error message? Have you tried mounting with the encoding options as recommended elsewhere? -- Liam signature.asc Description: Digital signature