If I understand the terminology correctly, an OSAX is a library of sorts that you can use to bundle a bunch of useful AppleScript routines, and I thought I read somewhere that it supports JXA also?
So I got to wondering if it would be useful for us to build one or more of these libraries that includes routines from this forum? I have no idea how you distribute OSAX files, how you update them, etc.
So, thoughts, anyone?
Hey Dan,
AppleScript Libraries are simple.
OSAXen are NOT simple.
-Chris
1 Like
ccstone:
OSAXen are NOT simple.
That just makes it sound more interesting. But I also trust your experience.
Thanks!
DanThomas:
So I got to wondering if it would be useful for us to build one or more of these libraries that includes routines from this forum? I have no idea how you distribute OSAX files, how you update them, etc.
So, thoughts, anyone?
OSAX libraries (scripting additions) were provided long before Apple introduced Script Libraries.
Since we now have Script Libraries, I see no need or benefit to creating/maintaining an OSAX.
Script libraries are easier to create, maintain
They are just as easy to distribute
They are just as easy to use
####Using Script Libraries in AppleScript
use AppleScript version "2.4"
use scripting additions
--- SCRIPT LIBRARIES ---
use JMLib : script "[LIB] JMichael Lib AS"
use SQLLib : script "SQLite Lib AS"
use BPLib : script "BridgePlus"
####Using Script Libraries in JXA
'use strict';
var app = Application.currentApplication()
app.includeStandardAdditions = true
//--- SCRIPT LIBRARIES ---
JMLib = Library('[LIB] JMichael Lib JXA')
2 Likes
Hey Dan,
https://developer.apple.com/library/mac/technotes/tn1164/_index.html
Tip of the iceberg.
If you really want to know more I can put you in contact with a couple of guys who are still writing osaxen.
-Chris
1 Like