[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Fwd: emacs lilypond-mode and the midi command
From: |
Daniel Hulme |
Subject: |
Re: Fwd: emacs lilypond-mode and the midi command |
Date: |
Sun, 8 Mar 2009 11:08:05 +0000 |
User-agent: |
Mutt/1.5.18 (2008-05-17) |
>> On Mar 7, 2009, at 4:05 AM, James E. Bailey wrote:
>>> On OSX, the lilypond mode for emacs doesn't properly escape
>>> filenames.
On Sat, Mar 07, 2009 at 04:44:41PM -0600, Tim McNamara wrote:
> Addendum: I was able to replicate this bheavior in Bash under Terminal.
> The problem appears to be how Bash handles spaces in filenames. Weird,
> in this day and age you'd think that shells would be intelligent enough
> to cope with this.
Guessing whether something is a filename or not is a really bad idea,
and can lead to very surprising behaviour. The accepted behaviour - that
spaces separate command-line arguments except when escaped or when the
whole argument is enclosed in quotes - is simple, consistent, and offers
few opportunities to accidentally delete all your files.
> There is a new revision of Bash out in the past few weeks, which
> perhaps gets around this.
I strongly doubt it. Any change like that would break backcompat and
startle all of its users.
[snip]
> If double quotes are put around the path, that seems to properly escape
> them, although even this was flakey on my Mac:
That's not enough. What if your path has double quotes in it? Or
backslashes? Anything that generates shell commands always needs to
fully escape the arguments.
--
"The rules of programming are transitory; only Tao is eternal.
Therefore you must contemplate Tao before you receive enlightenment."
"How will I know when I have received enlightenment?" asked the novice.
"Your program will then run correctly," replied the master.
signature.asc
Description: Digital signature