• 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
Problem Escaping osascript Command
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Problem Escaping osascript Command


  • Subject: Problem Escaping osascript Command
  • From: Rick Gordon <email@hidden>
  • Date: Tue, 22 Jan 2008 23:47:15 -0800

I am trying to set up an alias in my .tcshrc file. I generally use tcsh as my standard Terminal shell.

This line works fine as a Terminal command:

	osascript -e 'tell application "Finder" to reveal POSIX file "/"'

...but I want to create a "reveal" shell command, so I set up a line in my .tcshrc file:

I've tried a zillion variants (escaping interior quotes, swapping doubles and singles, etc.), but can't get it to work. Consider that what I'm trying to do with the "\!*" is to take the following path argument in the command line, enclosit in quotes, and pass it to the AppleScript.

	alias reveal 'osascript -e "tell application "Finder" to reveal POSIX file "\!*"'

I expect this should be simple for someone whose worked through the vagaries of this, but I would appreciate a nudge in the right direction.

Thanks.
--

___________________________________________________

RICK GORDON
EMERALD VALLEY GRAPHICS AND CONSULTING
___________________________________________________

WWW:   http://www.shelterpub.com
 _______________________________________________
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

  • Follow-Ups:
    • Re: Problem Escaping osascript Command
      • From: Matthew Smith <email@hidden>
    • Re: Problem Escaping osascript Command
      • From: Skeeve <email@hidden>
  • Prev by Date: Re: Functionality of delimiters
  • Next by Date: Re: Problem Escaping osascript Command
  • Previous by thread: Re: Functionality of delimiters
  • Next by thread: Re: Problem Escaping osascript Command
  • Index(es):
    • Date
    • Thread