• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: A question on shell scripting in AppleScript (Applescript-users Digest, Vol 2, Issue 91)
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: A question on shell scripting in AppleScript (Applescript-users Digest, Vol 2, Issue 91)


  • Subject: Re: A question on shell scripting in AppleScript (Applescript-users Digest, Vol 2, Issue 91)
  • From: Barry Wainwright <email@hidden>
  • Date: Wed, 09 Feb 2005 16:11:54 +0000

On 9/2/05 3:12 am, "Jonathan Levi MD" <email@hidden> wrote:

> At 12:02 PM -0800 2/8/05, email@hidden wrote:
>> Op 8-feb-05 om 16:21 heeft Francois Houle het volgende geschreven:
>>
>>> ..I have a shell script
>>> where the path to the file contains a Space.. Int he terminal I simply
>>>  wou go like this: File\ Name
>>> However, when the command is in an AppleScript, as below then I get
>>> that there is an unknown identifier [in]
>>> eg:Ý do shell script "rm /Users/myaccount/Documents/My\ Folder"
>>>  Ý
>>> How can I go around this ?
>
> Double the backslash, i.e.,
>
>    do shell script "open /System\\ Folder"--tested, it works
>
> Or put the whole name in quotes:
>
>    do shell script "Open \"/System Folder\""--also tested


Single quotes also work and have the advantage they do not need to be
'escaped' in applescript. Better still, use 'quoted form of...'

    do shell script "open '/System Folder' "
    do shell script "open " & quoted form of "System Folder"


--
Barry



 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

References: 
 >Re: Re: A question on shell scripting in AppleScript (Applescript-users Digest, Vol 2, Issue 91) (From: Jonathan Levi MD <email@hidden>)

  • Prev by Date: Re: where are the shell scripts ?
  • Next by Date: Re: where are the shell scripts ?
  • Previous by thread: Re: Re: A question on shell scripting in AppleScript (Applescript-users Digest, Vol 2, Issue 91)
  • Next by thread: Reading a csv file
  • Index(es):
    • Date
    • Thread