Search found 9 matches

by ComplexPoint
Mon Dec 11, 2023 7:04 am
Forum: Looking for AppleScripts…
Topic: Sorting Citations (from Dimensions.ai) in User14
Replies: 4
Views: 9891

Re: Sorting Citations (from Dimensions.ai) in User14

Here, FWIW is a JavaScript for Automation version which aims for a little more flexibility by: 1. Allowing you to specify the target field name at the top of the script, 2. deciding how many zeros are needed at the start (target width) by looking for the highest digit count seen in the data, 3. leav...
by ComplexPoint
Thu Mar 02, 2023 5:15 pm
Forum: Looking for AppleScripts…
Topic: Getting a specific reference format using JXA
Replies: 3
Views: 3568

Re: Getting a specific reference format using JXA

The trick is to load the scripting library in Script Editor: File > Open Dictionary... > Bookends and change the language selector at the top from AppleScript to JavaScript. Searching for format you will then see: format PublicationItem or list of PublicationItem : The publication item(s) that will ...
by ComplexPoint
Fri Sep 24, 2021 9:48 am
Forum: Looking for AppleScripts…
Topic: Importing from Delicious Library 3
Replies: 0
Views: 36650

Importing from Delicious Library 3

From Delicious Library 3 we can export a default XML file File > Export To > Another Application > XML The script below can convert: an .xml file exported from DL3 to a .bex file (json content, importable to Bookends) At the Bookends end, the menu path is: File > Import References > From File or Cli...
by ComplexPoint
Fri Sep 24, 2021 7:26 am
Forum: Bookends
Topic: Quickest route from Delicious Library 3 to Bookends ?
Replies: 3
Views: 3941

Re: Quickest route from Delicious Library 3 to Bookends ?

This is what I did in the end (JavaScript for Automation) (Probably a niche use case, so I haven't generalised it for others with file-choosing dialogs etc, but certainly could, if anyone else might find that useful) (() => { "use strict"; const main = () => { const fpDL3xml = "~/Desk...
by ComplexPoint
Thu Sep 23, 2021 5:25 pm
Forum: Bookends
Topic: Quickest route from Delicious Library 3 to Bookends ?
Replies: 3
Views: 3941

Quickest route from Delicious Library 3 to Bookends ?

Before I draft a script to write out Bookends JSON from DL3 plists,
is there a better route that I have missed ?

(Delicious Library 3 doesn't seem to export BibTeX, which was a previous route)
by ComplexPoint
Thu Sep 23, 2021 4:57 pm
Forum: Bookends
Topic: The new bundle id is ?
Replies: 1
Views: 3235

The new bundle id is ?

Your Ver 14 announcement mentions (but doesn't, as far as I can see, specify) a new bundle id.

Could you confirm to us what it is ?

Some firewall software panics when it sees such a change, and it would be helpful to have confirmation somewhere of what the correct bundle id should now be.
by ComplexPoint
Sun Oct 25, 2020 10:02 am
Forum: Looking for AppleScripts…
Topic: See what groups a publication belongs to.
Replies: 1
Views: 8582

Re: See what groups a publication belongs to.

Not sure if this is any faster (I would personally tend to do this in JS, which makes some of these things a bit easier and faster), but here FWIW is a variant approach in AppleScript: use AppleScript version "2.4" -- Yosemite (10.10) or later use scripting additions -- Rob Trew @2020 on r...
by ComplexPoint
Tue Dec 20, 2016 4:30 pm
Forum: Bookends
Topic: Bookends Scripting with OS X Javascript Automation
Replies: 13
Views: 31149

Re: Bookends Scripting with OS X Javascript Automation

It works great! I am currently experimenting with it. Unfortunately, the Script Editor is not a very good IDE and the documentation for JXA is still abysmal. Feels quite immature as a technology. But holds great promise. For an IDE, I tend to use Atom (free, excellent), with the Script and JS Beaut...
by ComplexPoint
Sun Jun 26, 2016 7:54 pm
Forum: Bookends
Topic: Bookends Scripting with OS X Javascript Automation
Replies: 13
Views: 31149

Re: Bookends Scripting with OS X Javascript Automation

With a couple of JavaScript helper functions – evalOSA and eventCode : // evalOSA :: String -> String -> IO String function evalOSA(strLang, strCode) { var oScript = ($.OSAScript || ( ObjC.import('OSAKit'), $.OSAScript)) .alloc.initWithSourceLanguage( strCode, $.OSALanguage.languageForName(strLang) ...