Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Mac OS X automation with Ruby

87 views
Skip to first unread message

Tony.M...@gmail.com

unread,
Jun 11, 2006, 8:44:46 PM6/11/06
to
I'm considering a switch (back) from the PC to a Mac/Intel laptop. I
want to know about options to automate applications. I used AppleScript
in the past (Mac OS 9, late 1990s) and remember it as particularly
painful.
Are there bindings for Mac automation that I can use from Ruby, by far
my most favorite language. Windows automation is a breeze with the
AutoIt/Ruby combo, and I'd hate to give that up in transitioning to the
Mac.

Cross-posted to comp.lang.ruby and comp.sys.mac.advocacy

Reply to newsgroups only. I do not check my gmail account.

Tim Murray

unread,
Jun 11, 2006, 8:48:24 PM6/11/06
to

Have you seen http://inquirylabs.com/blog/?p=21?

A google for macintosh ruby automate pulls up 124,000 English pages.

Une bévue

unread,
Jun 12, 2006, 3:05:02 AM6/12/06
to
<Tony.M...@gmail.com> wrote:

> I used AppleScript
> in the past (Mac OS 9, late 1990s) and remember it as particularly
> painful.
> Are there bindings for Mac automation that I can use from Ruby, by far
> my most favorite language.

their is a ruby/applescript binding called "RubyAEOSA" see
<http://www.fobj.com/rubyaeosa/>
--
une bévue

Premshree

unread,
Jun 12, 2006, 4:33:51 AM6/12/06
to

Or, of course, you could run an AppleScript from within Ruby:

script = <<SCRIPT
tell application "foo"
[...]
end tell
SCRIPT

`osascript -ss -e '#{script}'`

:-)

Premshree

Dale

unread,
Jun 12, 2006, 7:18:01 AM6/12/06
to
Tony.M...@gmail.com wrote:
> I'm considering a switch (back) from the PC to a Mac/Intel laptop. I
> want to know about options to automate applications. I used AppleScript
> in the past (Mac OS 9, late 1990s) and remember it as particularly
> painful.
> Are there bindings for Mac automation that I can use from Ruby, by far
> my most favorite language. Windows automation is a breeze with the
> AutoIt/Ruby combo, and I'd hate to give that up in transitioning to the
> Mac.

I don't think you'll find Ruby as well supported on the Mac for
automation as it is on Windows.

Other than AppleScript 'bindings'/OSA there's support for Javascript,
Python and Ruby. I've put these languages in the order they're best
supported (in my limited knowledge, without having used them). A Google
search will turn up info about each.

0 new messages