Re: Simply deleting a fil
Re: Simply deleting a fil
- Subject: Re: Simply deleting a fil
- From: Roger Howard <email@hidden>
- Date: Fri, 17 Apr 2009 13:32:53 -0700
On Fri, 17 Apr 2009 15:05:20 -0400, "Mark J. Reed" <email@hidden>
wrote:
> On Fri, Apr 17, 2009 at 2:10 PM, Roger Howard
> <email@hidden> wrote:
>> Are there any cases where "quoted form of", when using a POSIX path *as*
>> a
>> path in a shell command, is unnecessary?
>
> Well, it's not strictly necssary if the POSIX paths you're dealing
> with are all free of spaces and other special characters. But I
> definitely recommend using it all the time.
Right - it doesn't hurt when you use it unnecessarily (to quote a path with
no funny characters or spaces), but it does hurt when you don't, so I just
always use it...
> Doug's reply betrays a potential misunderstanding, however. Only use
> "quoted form of" for individual items that you want the shell to see
> as a single "thing". One argument. One filename. Do not use it for
> entire shell command lines, because it removes the significance of the
> spaces within, so the shell will see only one "word". And chances are
> you don't have a program named "ls -l My Documents" sitting in
> /usr/bin. :)
Of course - I migth not have been clear... I use it to escape individual
paths, before I compose a command string to pass to do shell script. It
saves a lot of trouble in the long run, not to mention the potential harm
(however unlikely) of an improperly quoted path causing the wrong thing to
happen.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden