Problem Escaping osascript Command
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