Re: preserving literal text in AppleScripts
Re: preserving literal text in AppleScripts
- Subject: Re: preserving literal text in AppleScripts
- From: "Mark J. Reed" <email@hidden>
- Date: Fri, 15 Dec 2006 20:52:48 -0500
AppleScript doesn't have anything analogous to here-documents or raw
strings etc. Instead of passing a large string containing a complex
command to "do shell script", why not store it in a script file and
just run that?
On 12/15/06, Cameron Hayne <email@hidden> wrote:
Is there any good way of preserving literal text that is embedded in
an AppleScript?
What I'm looking for is something analogous to the "here documents"
of Perl or Bash where I can define a variable to have the contents of
the following text - from this delimiter up to a terminating
delimiter - where AppleScript will make absolutely no changes and no
interpretation of the text whatsoever.
In particular, I want to be able to use quotes and backslashes, etc
in this text and not have to escape those quotes (with backslashes).
The context of this is for text that is code to be passed to 'do
shell script'. I'd like to have a good (nice) way of embedding
arbitrarily complicated Bash or Perl scripts inside an AppleScript. I
don't want to have to manually insert backslashes in this code where
needed to preserve it from interpretation by AppleScript.
--
Cameron Hayne
email@hidden
_______________________________________________
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/mailman//archives/applescript-users
This email sent to email@hidden
--
Mark J. Reed <email@hidden>
_______________________________________________
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/mailman//archives/applescript-users
This email sent to email@hidden