D&C Lug - Home Page
Devon & Cornwall Linux Users' Group

[ Date Index ][ Thread Index ]
[ <= Previous by date / thread ] [ Next by date / thread => ]

Re: [LUG] Filename / Directory Names with Spaces in was: LUG Stuff...



Brough, Tom wrote:
Clive Darke said:


Just a small thing I would like to correct.
"Linux does not like spaces in folder names" is not true, although many
scripts are badly written and cannot handle imbedded spaces in file or
directory (folder) names.  If you want imbedded spaces in a name, just
surround it in quotes (either ' or " will do).


While this is all true I would personally discourage the use of spaces in
file and directory (folder) names. Although spaces on a fixed font command
line are very easy to see, they are a lot harder to identify in a
proportional font. IMO at best it doesnt aid the programming or scripting
process  and at worst it is a hinderance. By convention spaces have been
used as delimiters for words and parameters in most natural languages,
programming languages and command line interfaces, almost universally. Much

To the point where it is hard to come up with examples where this is not the case. Especially with natural languages.


that I hate to bate Microsoft ;-) I curse the day that it unilaterally
decided that spaces in filenames would be a neat idea.

So much so that Windows needs all sorts of kludges to handle this. Especially under VFAT, where it can be almost random which version of a filename winds up in a .LNK file or registry key. (It's even possible to get references of the form "C:\PROGRA~1\Some Program".)


Of course once Microsoft sneezed the rest of the IT world had to catch a
cold. Yes Ok it may look good to an end user, but as a programmer  /
scripter it has caused no end of problems. And yes agreed a good scripter /
programmer should be able to face these challenges, but they are not
challenges for the common good, rather they are distractions that hamper
real progress.

Using spaces in filenames also creates plenty of "fun" with HTML hyperlinks.


Please, please, please, please, please avoid using spaces in file and
directory names.

I find myself giving exactly the same instruction far too often :)



Attachment: signature.asc
Description: OpenPGP digital signature


Lynx friendly