Very useful script from our @Iandol

A place for users to ask each other questions, make suggestions, and discuss Bookends.
Dellu
Posts: 144
Joined: Sun Mar 27, 2016 5:30 am

Very useful script from our @Iandol

Post by Dellu »

I would like to say thank you for @iandol, for his great script https://github.com/iandol/bookends-tools

The script has been very useful for me. It liberated me from the quirks of any writing software. Now, I can cite on any application: Markdown editors, RTF editors, Scrivener, Word, online editors, even in Latex...total freedom and independence from the quirks of any word processor/editor. I have been dreaming about this kind of system for a while.

This is so good.

Thank you man!

Cassady
Posts: 167
Joined: Thu Aug 22, 2013 3:48 pm
Location: Sqornshellous

Re: Very useful script from our @Iandol

Post by Cassady »

Another vote of thanks! Amazing workflow this!!

taja
Posts: 50
Joined: Sun Feb 12, 2012 10:39 pm

Re: Very useful script from our @Iandol

Post by taja »

Yes, it's wonderful; I bought Alfred's Powerpack just so I could use it. Jon: I wonder whether there would ever be any scope for integrating something like this into Bookends? It's really transformative, but I imagine that the additional cost of the Powerpack means not many Bookends users will end up using it.

Jon
Site Admin
Posts: 9023
Joined: Tue Jul 13, 2004 6:27 pm
Location: Bethesda, MD
Contact:

Re: Very useful script from our @Iandol

Post by Jon »

I have no experience with apps like Alfred, so I don't really know how they could be integrated with Bookends (and you're right, since a third party app is required I'm not likely to build it into Bookends). How do you see the scripts somehow being invoked from within Bookends as being substantially better than invoking them as you do now (I don't a minor convenience, like saving a click or two, but fundamentally better)?

Jon
Sonny Software

taja
Posts: 50
Joined: Sun Feb 12, 2012 10:39 pm

Re: Very useful script from our @Iandol

Post by taja »

I suppose an equivalent would be something like the interface provided by Magic Citation in Papers or the Zotero cite-while-you-write plugin, so the same justifications apply as for those. The benefits can in some respects be reduced to saving a click or two, but just as important i think are the benefits of not having to lose focus by leaving the app one is working in, and being able to paste citations frictionlessly into different apps rather than only the word processor selected in Bookends preferences.

One example: I'm completing a book MS, which has involved quickly adding multiple footnotes from different sources, and writing notes on the hoof that also contain many references in a couple of different apps. So I need to find and select many references in Bookends in a short space of time, over and over again. Without iandol's workflow this entails:

(1) switching out of Scrivener/Devonthink/NValt to Bookends, which means mousing or alt-tabbing (though I use a KB shortcut and script) (2) KB shortcut to select search (3) typing search terms (3) mousing to select the reference (4) KB shortcut to copy/paste a citation.

If I'm using an app other than the one selected as a word processor in Bookends I have to manually copy/paste, adding another step. Leaving the app I'm writing in and switching to another UI means losing focus, and when done multiple times in quick succession from sentence to sentence, or paragraph to paragraph, quickly gets tiresome. The hits list helps, but requires a bit more clicking around. Also, with 7000+ refs, Bookends' interface is quite laggy for me (delay after every click and KB shortcut and laggy scrolling) so I don't like switching to it for short tasks: each click/KB shortcut has a greater overhead than in say, Scrivener.

The Alfred workflow has no UI lag and does not require leaving one'the current app: (1) KB shortcut to invoke (2) type search terms (3) press enter to paste citation. With a modifier key (rather than different shortcuts) the workflow allows several different functions to be performed: pasting the formatted citation, showing reference in bookends, and opening the attachment. This may only involve saving one or two clicks, but repeated over and over again in a short space of time it adds up, is a lot less mentally taxing, and cuts out the mental overhead of switching between apps/windows, remembering various keyboard shortcuts and waiting for Bookends window UI to catch up. Just my two cents, but I'm sure others who have used the workflow (or equivalents for other apps) can chime in.
Last edited by taja on Mon Jul 02, 2018 8:56 am, edited 1 time in total.

Jon
Site Admin
Posts: 9023
Joined: Tue Jul 13, 2004 6:27 pm
Location: Bethesda, MD
Contact:

Re: Very useful script from our @Iandol

Post by Jon »

Thanks for the information. One small possibly helpful point you may not be aware of -- you can change the linked app on-the-fly with File -> Link To. When you relaunch Bookends it will return to the default set in preferences.

Jon
Sonny Software

iandol
Posts: 362
Joined: Fri Jan 25, 2008 2:31 pm

Re: Very useful script from our @Iandol

Post by iandol »

Thanks also to kseggleton, dave83 and naupaka whose scripts are part of bookends-tools collection. And thanks to Jon, who has continually modified and upgraded Bookends to improve its Applescript integration making bookends tools work better!

Jon, if you've ever tried Magic Citations from Papers, you'll get a sense of how the Alfred workflow works. It is a separate "floating" interface you can trigger from anywhere at any time that does quick searching through your refs (thanks to applescript events), then gives you options for citing / opening etc. I think the advantage of Alfred is that it is easy to customise the interface to change how modifier keys work etc. For Jon to do this would take more time.

Another advantage of Alfred is being able to work with a selection. I don't know for others, but since Jon added Quick add, I am using bequickadd as the main way to import DOIs and PMIDs, you highlight these in any app then Alfred>bequickadd and it gets added to your database without any fuss.

Anyway, thank you all for your encouragement! A new version will be out in a few days that shows first and last authors with their first initials (not just first authors as before).

Jon
Site Admin
Posts: 9023
Joined: Tue Jul 13, 2004 6:27 pm
Location: Bethesda, MD
Contact:

Re: Very useful script from our @Iandol

Post by Jon »

Thanks indeed to landol for the Alfred scripts. I don't think I would try to integrate those scripts into Bookends per se -- that's why we have AppleEvents extensibility. However, I am open to the notion of integrating a global floating palette that would allow one to access Bookends references from within other apps and insert temporary citations (in fact, as this post appeared, I've been working on opening such a window with a double-Option key press, with apologies to Papers). This is a nontrivial undertaking, and I'm not sure how useful it will be in the end, but I'm exploring it. If it gets anywhere no doubt I'll post more to get feedback.

Jon
Sonny Software

Dellu
Posts: 144
Joined: Sun Mar 27, 2016 5:30 am

Re: Very useful script from our @Iandol

Post by Dellu »

Jon wrote:
Tue Jul 03, 2018 1:19 pm
I am open to the notion of integrating a global floating palette that would allow one to access Bookends references from within other apps and insert temporary citations (in fact, as this post appeared, I've been working on opening such a window with a double-Option key press, with apologies to Papers). This is a nontrivial undertaking, and I'm not sure how useful it will be in the end, but I'm exploring it.

Jon
Sonny Software
That will be an interesting feature for BE.

Two conditions that would make it very useful:
a) universality: the Citation feature in Papers has failed because of the listed number of apps. The user has to constantly request for this or that app to be supported by Citation (originally was called Magic Manuscript). If it cannot insert on any app (comes with prefixed lists like Scrivener, Word etc), as the mac environment is evolving fast and new writing tools are showing up, the feature would be hard to maintain in the long run. We will be nagging you to support this app, or that app. You better leave it as it is (Alfred) if your script is going to be restricted, listed number of apps.
b) Cosumizability: some of us want to cite with the Pandoc format; others want MMD, and some Latex. The best part of this script is its customizability. I am using it to insert references in Latex format across all my apps (Textedit, Tinderbox, Scrivener, Devonthink).

Jon
Site Admin
Posts: 9023
Joined: Tue Jul 13, 2004 6:27 pm
Location: Bethesda, MD
Contact:

Re: Very useful script from our @Iandol

Post by Jon »

a) In addition to Copy Citation (which does require some info about the target app) it would support drag and drop of temporary citations. That will work with any text-based a;;.

b) support for other styles could potentially be added (whether there was a global floating window or not). Bookends already supports citing for BibTeX (which I assume would be the same as LaTeX). The other formats I don't know well enough to comment, except that they didn't seem trivial when I checked them out previously.

Jon
Sonny Software

Jon
Site Admin
Posts: 9023
Joined: Tue Jul 13, 2004 6:27 pm
Location: Bethesda, MD
Contact:

Re: Very useful script from our @Iandol

Post by Jon »

I should add that what I envision for Bookends is a floating window of more limited capabilities than Paper's Magic Citations. Namely, searching your library, inserting temporary (or final) citations, using Quicklook to show attachments, and navigation back to Bookends.

Jon
Sonny Software

iandol
Posts: 362
Joined: Fri Jan 25, 2008 2:31 pm

Re: Very useful script from our @Iandol

Post by iandol »

Jon, I think that feature set is a good core. For my citation script, the options are:
  • insert bookends configured temporary citation
  • insert pandoc temporary citation — this is simply the key(user1) field wrapped in [@ … ], e.g. [@doe1996]
  • insert multimarkdown temporary citation: [#user1]
  • optionally insert temporary citation wrapped in a RTF link with link back to open the ref in Bookends.
  • insert the formatted citation
  • focus that citation in bookends
  • open the attachment
Being able to quicklook from the interface would be great; I can't do that with Alfred while still keeping the alfred window open. So your basic feature set would cover most of what my citation tool does. For example a Bookends user can already configure his temporary citation to insert Pandoc style, so my selectable temporary citation styles are not strictly necessary. I find it useful to be able to choose my temporary citation style, but I doubt most users would...

Jon
Site Admin
Posts: 9023
Joined: Tue Jul 13, 2004 6:27 pm
Location: Bethesda, MD
Contact:

Re: Very useful script from our @Iandol

Post by Jon »

I'll let you know when this feature is ready for beta testing. Your feedback will help.

Jon
Sonny Software

Cassady
Posts: 167
Joined: Thu Aug 22, 2013 3:48 pm
Location: Sqornshellous

Re: Very useful script from our @Iandol

Post by Cassady »

Fantastic news! Thank you Jon for giving this consideration, and @landol for the initial workflow!

Jon
Site Admin
Posts: 9023
Joined: Tue Jul 13, 2004 6:27 pm
Location: Bethesda, MD
Contact:

Re: Very useful script from our @Iandol

Post by Jon »

I have an advanced prototype of this functionality ready for outside input. If anyone who has commented on this thread want to give their input please write to me to request it.

Thanks,

Jon
Sonny Software

Post Reply