• 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
sh-appscript (was: Re: Modifying incoming mail subject)
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

sh-appscript (was: Re: Modifying incoming mail subject)


  • Subject: sh-appscript (was: Re: Modifying incoming mail subject)
  • From: has <email@hidden>
  • Date: Fri, 28 Dec 2007 19:48:45 +0000

On 28 Dec 2007, at 03:07, Mark J. Reed wrote:

Has: it would seem that the best way to integrate appscript
functionality with the shell would be to provide a cli that can be
called from the shell, rather than extending the shell itself..

Apple event support (which allows scripts to control applications) and OSA component support (which allows applications to control scripts) are largely orthogonal, although they do require some integration if they're to be used in combination.


FWIW, implementing an Apple event bridge only gives the most bang-per- buck (since most tasks don't require attachability), and is the easiest place to start. Quite what form an Apple event bridge for the shell would take, I'm not sure, given that the two type systems are radically different (weak, dynamic typing versus untyped). The best approach may be some sort of adaptor-based system where the more complex Apple event types are represented as opaque binary data but can be converted to/from shell-friendly formats via additional commands. e.g. Object specifiers might be written using an XPath-like syntax, then converted to/from an opaque typed binary format via an 'osaref' adaptor command:

    osacmd --app Finder get `osaref /home/folders[$1]/name`

Not a trivial design problem, but an interesting challenge for anyone determined enough to take it on. Like I say, I'm already solid with existing projects, but I'd be happy to provide advice and assistance if someone else fancies a go.

has
--
http://appscript.sourceforge.net
http://rb-appscript.rubyforge.org

_______________________________________________
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
References: 
 >Modifying incoming mail subject (From: Michaël Grünewald <email@hidden>)
 >Re: Modifying incoming mail subject (From: has <email@hidden>)
 >Re: Modifying incoming mail subject (From: Michaël Grünewald <email@hidden>)
 >Re: Modifying incoming mail subject (From: "Mark J. Reed" <email@hidden>)

  • Prev by Date: Re: Save As in Excel
  • Next by Date: Re: Safari Scripting Help (Newbie stuff) Complete!
  • Previous by thread: Re: Modifying incoming mail subject
  • Next by thread: Re: Modifying incoming mail subject
  • Index(es):
    • Date
    • Thread