From cfab973b4c38f5b403a831f956f214e34c0651b9 Mon Sep 17 00:00:00 2001 From: Andreas Gerler Date: Sun, 22 Dec 2024 13:10:56 +0100 Subject: [PATCH] update org-mac-link Signed-off-by: Andreas Gerler --- .../org-mac-link-pkg.el | 19 --- .../org-mac-link-autoloads.el | 123 +++++++---------- .../org-mac-link-pkg.el | 15 +++ .../org-mac-link.el | 127 +++++++++++++----- 4 files changed, 154 insertions(+), 130 deletions(-) delete mode 100644 elpa/org-mac-link-20230228.1127/org-mac-link-pkg.el rename elpa/{org-mac-link-20230228.1127 => org-mac-link-20231016.2047}/org-mac-link-autoloads.el (67%) create mode 100644 elpa/org-mac-link-20231016.2047/org-mac-link-pkg.el rename elpa/{org-mac-link-20230228.1127 => org-mac-link-20231016.2047}/org-mac-link.el (89%) diff --git a/elpa/org-mac-link-20230228.1127/org-mac-link-pkg.el b/elpa/org-mac-link-20230228.1127/org-mac-link-pkg.el deleted file mode 100644 index 5758e313..00000000 --- a/elpa/org-mac-link-20230228.1127/org-mac-link-pkg.el +++ /dev/null @@ -1,19 +0,0 @@ -(define-package "org-mac-link" "20230228.1127" "Insert org-mode links to items selected in various Mac apps" - '((emacs "27.1")) - :commit "3a30a937e135a6637a5126e2ac096b6c90584045" :authors - '(("Anthony Lander" . "anthony.lander@gmail.com") - ("John Wiegley" . "johnw@gnu.org") - ("Christopher Suckling ") - ("Daniil Frumin" . "difrumin@gmail.com") - ("Alan Schmitt" . "alan.schmitt@polytechnique.org") - ("Mike McLean" . "mike.mclean@pobox.com")) - :maintainers - '(("Aimé Bertrand" . "aime.bertrand@macowners.club")) - :maintainer - '("Aimé Bertrand" . "aime.bertrand@macowners.club") - :keywords - '("files" "wp" "url" "org") - :url "https://gitlab.com/aimebertrand/org-mac-link") -;; Local Variables: -;; no-byte-compile: t -;; End: diff --git a/elpa/org-mac-link-20230228.1127/org-mac-link-autoloads.el b/elpa/org-mac-link-20231016.2047/org-mac-link-autoloads.el similarity index 67% rename from elpa/org-mac-link-20230228.1127/org-mac-link-autoloads.el rename to elpa/org-mac-link-20231016.2047/org-mac-link-autoloads.el index edf68ce6..edf117fc 100644 --- a/elpa/org-mac-link-20230228.1127/org-mac-link-autoloads.el +++ b/elpa/org-mac-link-20231016.2047/org-mac-link-autoloads.el @@ -1,12 +1,14 @@ -;;; org-mac-link-autoloads.el --- automatically extracted autoloads -*- lexical-binding: t -*- -;; +;;; org-mac-link-autoloads.el --- automatically extracted autoloads (do not edit) -*- lexical-binding: t -*- +;; Generated by the `loaddefs-generate' function. + +;; This file is part of GNU Emacs. + ;;; Code: -(add-to-list 'load-path (directory-file-name - (or (file-name-directory #$) (car load-path)))) +(add-to-list 'load-path (or (and load-file-name (directory-file-name (file-name-directory load-file-name))) (car load-path))) + -;;;### (autoloads nil "org-mac-link" "org-mac-link.el" (0 0 0 0)) ;;; Generated autoloads from org-mac-link.el (autoload 'org-mac-link-get-link "org-mac-link" "\ @@ -14,68 +16,51 @@ Prompt for an application to grab a link from. When done, go grab the link, and insert it at point. If a region is active, that will be the link's description. -\(fn &optional BEG END)" t nil) - +(fn &optional BEG END)" t) (autoload 'org-mac-link-firefox-get-frontmost-url "org-mac-link" "\ -Get the link to the frontmost window of the Firefox.app." t nil) - +Get the link to the frontmost window of the Firefox.app." t) (autoload 'org-mac-link-firefox-insert-frontmost-url "org-mac-link" "\ -Insert the link to the frontmost window of the Firefox.app." t nil) - +Insert the link to the frontmost window of the Firefox.app." t) (autoload 'org-mac-link-vimperator-get-frontmost-url "org-mac-link" "\ -Get the link to the frontmost window of the Firefox.app with Vimperator." t nil) - +Get the link to the frontmost window of the Firefox.app with Vimperator." t) (autoload 'org-mac-link-vimperator-insert-frontmost-url "org-mac-link" "\ -Insert the link to the frontmost window of the Firefox.app with Vimperator." t nil) - +Insert the link to the frontmost window of the Firefox.app with Vimperator." t) (autoload 'org-mac-link-chrome-get-frontmost-url "org-mac-link" "\ -Get the link to the frontmost window of the Chrome.app." t nil) - +Get the link to the frontmost window of the Chrome.app." t) (autoload 'org-mac-link-chrome-insert-frontmost-url "org-mac-link" "\ -Insert the link to the frontmost window of the Chrome.app." t nil) - +Insert the link to the frontmost window of the Chrome.app." t) +(autoload 'org-mac-link-chromium-get-frontmost-url "org-mac-link" "\ +Get the link to the frontmost window of the Chromium.app." t) +(autoload 'org-mac-link-chromium-insert-frontmost-url "org-mac-link" "\ +Insert the link to the frontmost window of the Chromium.app." t) (autoload 'org-mac-link-brave-get-frontmost-url "org-mac-link" "\ -Get the link to the frontmost window of the Brave.app." t nil) - +Get the link to the frontmost window of the Brave.app." t) (autoload 'org-mac-link-brave-insert-frontmost-url "org-mac-link" "\ -Insert the link to the frontmost window of the Brave.app." t nil) - +Insert the link to the frontmost window of the Brave.app." t) (autoload 'org-mac-link-safari-get-frontmost-url "org-mac-link" "\ -Get the link to the frontmost window of the Safari.app." t nil) - +Get the link to the frontmost window of the Safari.app." t) (autoload 'org-mac-link-safari-insert-frontmost-url "org-mac-link" "\ -Insert the link to the frontmost window of the Safari.app." t nil) - +Insert the link to the frontmost window of the Safari.app." t) (autoload 'org-mac-link-together-get-selected "org-mac-link" "\ -Get the links to selected items in the Together.app." t nil) - +Get the links to selected items in the Together.app." t) (autoload 'org-mac-link-together-insert-selected "org-mac-link" "\ -Insert the links to selected items in the Together.app." t nil) - +Insert the links to selected items in the Together.app." t) (autoload 'org-mac-link-finder-item-get-selected "org-mac-link" "\ -Get the links to selected items in the Finder.app." t nil) - +Get the links to selected items in the Finder.app." t) (autoload 'org-mac-link-finder-insert-selected "org-mac-link" "\ -Insert the links to selected items in the Finder.app." t nil) - +Insert the links to selected items in the Finder.app." t) (autoload 'org-mac-link-addressbook-item-get-selected "org-mac-link" "\ -Get the links to selected items in the addressbook." t nil) - +Get the links to selected items in the addressbook." t) (autoload 'org-mac-link-addressbook-item-insert-selected "org-mac-link" "\ -Insert the links to selected items in the addressbook." t nil) - +Insert the links to selected items in the addressbook." t) (autoload 'org-mac-link-skim-get-page "org-mac-link" "\ -Get the link to the page in the Skim.app." t nil) - +Get the link to the page in the Skim.app." t) (autoload 'org-mac-link-skim-insert-page "org-mac-link" "\ -Insert the link to the page in the Skim.app." t nil) - +Insert the link to the page in the Skim.app." t) (autoload 'org-mac-link-acrobat-get-page "org-mac-link" "\ -Get the link to the page in the Adobe Acrobat Pro.app." t nil) - +Get the link to the page in the Adobe Acrobat Pro.app." t) (autoload 'org-mac-link-acrobat-insert-page "org-mac-link" "\ -Insert the link to the page in the Adobe Acrobat Pro.app." t nil) - +Insert the link to the page in the Adobe Acrobat Pro.app." t) (autoload 'org-mac-link-outlook-message-get-links "org-mac-link" "\ Create links to selected or flagged messages in Microsoft Outlook.app. This will use AppleScript to get the message-id and the subject of the @@ -84,31 +69,26 @@ When SELECT-OR-FLAG is \"s\", get the selected messages (this is also the default). When SELECT-OR-FLAG is \"f\", get the flagged messages. The Org-syntax text will be pushed to the kill ring, and also returned. -\(fn &optional SELECT-OR-FLAG)" t nil) - +(fn &optional SELECT-OR-FLAG)" t) (autoload 'org-mac-link-outlook-message-insert-selected "org-mac-link" "\ Insert a link to the messages currently selected in Microsoft Outlook.app. This will use AppleScript to get the message-id and the subject -of the active mail in Microsoft Outlook.app and make a link out of it." t nil) - +of the active mail in Microsoft Outlook.app and make a link out of it." t) (autoload 'org-mac-link-outlook-message-insert-flagged "org-mac-link" "\ Asks for an ORG-BUFFER and a heading within it, and replace message links. If ORG-HEADING exists, delete all mac-outlook:// links in heading's first level. If heading doesn't exist, create it at point-max. Insert list of mac-outlook:// links to flagged mail after heading. -\(fn ORG-BUFFER ORG-HEADING)" t nil) - +(fn ORG-BUFFER ORG-HEADING)" t) (autoload 'org-mac-link-evernote-note-insert-selected "org-mac-link" "\ Insert a link to the notes currently selected in Evernote.app. This will use AppleScript to get the note id and the title of the -note(s) in Evernote.app and make a link out of it/them." t nil) - +note(s) in Evernote.app and make a link out of it/them." t) (autoload 'org-mac-link-devonthink-item-insert-selected "org-mac-link" "\ -Insert a link to the item(s) currently selected in DEVONthink Pro Office. +Insert a link to the item(s) currently selected in DEVONthink*.app. This will use AppleScript to get the `uuid'(s) and the name(s) of the -selected items in DEVONthink Pro Office and make link(s) out of it/them." t nil) - +selected items in DEVONthink*.app and make link(s) out of it/them." t) (autoload 'org-mac-link-mail-get-links "org-mac-link" "\ Create links to the messages currently selected or flagged in Mail.app. This will use AppleScript to get the message-id and the subject of the @@ -117,39 +97,34 @@ When SELECT-OR-FLAG is \"s\", get the selected messages (this is also the default). When SELECT-OR-FLAG is \"f\", get the flagged messages. The Org-syntax text will be pushed to the kill ring, and also returned. -\(fn &optional SELECT-OR-FLAG)" t nil) - +(fn &optional SELECT-OR-FLAG)" t) (autoload 'org-mac-link-mail-insert-selected "org-mac-link" "\ Insert a link to the messages currently selected in Mail.app. This will use AppleScript to get the message-id and the subject of the -active mail in Mail.app and make a link out of it." t nil) - +active mail in Mail.app and make a link out of it." t) (autoload 'org-mac-link-mail-insert-flagged "org-mac-link" "\ Asks for an ORG-BUFFER and a heading within it, and replace message links. If ORG-HEADING exists, delete all message:// links within heading's first level. If heading doesn't exist, create it at point-max. Insert list of message:// links to flagged mail after heading. -\(fn ORG-BUFFER ORG-HEADING)" t nil) - +(fn ORG-BUFFER ORG-HEADING)" t) (autoload 'org-mac-link-qutebrowser-get-frontmost-url "org-mac-link" "\ -Get the link to the frontmost window of the qutebrowser.app." t nil) - +Get the link to the frontmost window of the qutebrowser.app." t) (autoload 'org-mac-link-qutebrowser-insert-frontmost-url "org-mac-link" "\ -Insert the link to the frontmost window of the qutebrowser.app." t nil) - +Insert the link to the frontmost window of the qutebrowser.app." t) (register-definition-prefixes "org-mac-link" '("org-mac-link-")) - -;;;*** -;;;### (autoloads nil nil ("org-mac-link-pkg.el") (0 0 0 0)) +;;; End of scraped data + +(provide 'org-mac-link-autoloads) -;;;*** - ;; Local Variables: ;; version-control: never ;; no-byte-compile: t ;; no-update-autoloads: t -;; coding: utf-8 +;; no-native-compile: t +;; coding: utf-8-emacs-unix ;; End: + ;;; org-mac-link-autoloads.el ends here diff --git a/elpa/org-mac-link-20231016.2047/org-mac-link-pkg.el b/elpa/org-mac-link-20231016.2047/org-mac-link-pkg.el new file mode 100644 index 00000000..adedbd03 --- /dev/null +++ b/elpa/org-mac-link-20231016.2047/org-mac-link-pkg.el @@ -0,0 +1,15 @@ +;; -*- no-byte-compile: t; lexical-binding: nil -*- +(define-package "org-mac-link" "20231016.2047" + "Insert org-mode links to items selected in various Mac apps." + '((emacs "27.1")) + :url "https://gitlab.com/aimebertrand/org-mac-link" + :commit "e30171a6e98db90787ab8a23b3a7dc4fd13b10f9" + :revdesc "e30171a6e98d" + :keywords '("files" "wp" "url" "org") + :authors '(("Anthony Lander" . "anthony.lander@gmail.com") + ("John Wiegley" . "johnw@gnu.org") + ("Christopher Suckling" . "sucklingatgmaildotcom") + ("Daniil Frumin" . "difrumin@gmail.com") + ("Alan Schmitt" . "alan.schmitt@polytechnique.org") + ("Mike McLean" . "mike.mclean@pobox.com")) + :maintainers '(("Aimé Bertrand" . "aime.bertrand@macowners.club"))) diff --git a/elpa/org-mac-link-20230228.1127/org-mac-link.el b/elpa/org-mac-link-20231016.2047/org-mac-link.el similarity index 89% rename from elpa/org-mac-link-20230228.1127/org-mac-link.el rename to elpa/org-mac-link-20231016.2047/org-mac-link.el index dd41bf58..21d647ed 100644 --- a/elpa/org-mac-link-20230228.1127/org-mac-link.el +++ b/elpa/org-mac-link-20231016.2047/org-mac-link.el @@ -8,7 +8,8 @@ ;; Daniil Frumin ;; Alan Schmitt ;; Mike McLean -;; Version: 1.9 +;; Package-Version: 20231016.2047 +;; Package-Revision: e30171a6e98d ;; Keywords: files, wp, url, org ;; Package-Requires: ((emacs "27.1")) ;; Maintainer: Aimé Bertrand @@ -51,11 +52,12 @@ ;; Vimperator/Firefox.app - Grab the url of the frontmost tab in the frontmost window ;; Safari.app - Grab the url of the frontmost tab in the frontmost window ;; Google Chrome.app - Grab the url of the frontmost tab in the frontmost window +;; Chromium.app - Grab the url of the frontmost tab in the frontmost window ;; Brave.app - Grab the url of the frontmost tab in the frontmost window ;; Together.app - Grab links to the selected items in the library list ;; Skim.app - Grab a link to the selected page in the topmost pdf document ;; Microsoft Outlook.app - Grab a link to the selected message in the message list -;; DEVONthink Pro Office.app - Grab a link to the selected DEVONthink item(s); open DEVONthink item by reference +;; DEVONthink*.app - Grab a link to the selected DEVONthink item(s); open DEVONthink item by reference ;; Evernote.app - Grab a link to the selected Evernote item(s); open Evernote item by ID ;; qutebrowser.app - Grab the url of the frontmost tab in the frontmost window ;; @@ -85,6 +87,9 @@ ;; customizing the group `org-mac-link'. Changes take effect ;; immediately. ;; +;; You can also add grab handlers for other apps, just by updating +;; `org-mac-link-descriptors', for instance: +;; `(push '("W" "ord" my-word-handler t) org-mac-link-descriptors)' ;; ;;; Code: @@ -122,17 +127,11 @@ Do not escape spaces as the AppleScript call will quote this string." :type 'string) (defcustom org-mac-link-devonthink-app-p t - "Add menu option [d]EVONthink to grab links from DEVONthink Pro Office.app." - :tag "Grab DEVONthink Pro Office.app links" + "Add menu option [d]EVONthink to grab links from DEVONthink*.app." + :tag "Grab DEVONthink*.app links" :group 'org-mac-link :type 'boolean) -(defcustom org-mac-link-devonthink-app-name "DEVONthink Pro" - "Name of DEVONthink Pro application." - :tag "Name of DEVONthink Pro application" - :group 'org-mac-link - :type 'string) - (defcustom org-mac-link-addressbook-app-p t "Add menu option [a]ddressbook to grab links from AddressBook.app." :tag "Grab AddressBook.app links" @@ -163,6 +162,12 @@ Do not escape spaces as the AppleScript call will quote this string." :group 'org-mac-link :type 'boolean) +(defcustom org-mac-link-chromium-app-p t + "Add menu option [C]hromium to grab links from Chromium.app." + :tag "Grab Chromium.app links" + :group 'org-mac-link + :type 'boolean) + (defcustom org-mac-link-brave-app-p t "Add menu option [b]rave to grab links from Brave.app." :tag "Grab Brave.app links" @@ -237,6 +242,34 @@ Do not escape spaces as the AppleScript call will quote this string." (setq return (shell-command-to-string cmd)) (concat "\"" (org-trim return) "\"")))) + +;; List of lists representing grab menu items. +;; +;; Each element corresponds to one application, listing the menu shortcut, +;; rest of the application name, grab handler function name, and +;; predicate indicating whether that application should be shown in the menu. +;; +;; The predicates are customizable variables whose value is reloaded upon each +;; invocation of the grab menu, see `org-mac-link-get-link'. +(defvar org-mac-link-descriptors + `(("F" "inder" org-mac-link-finder-insert-selected org-mac-link-finder-app-p) + ("m" "ail" org-mac-link-mail-insert-selected org-mac-link-mail-app-p) + ("d" "EVONthink" org-mac-link-devonthink-item-insert-selected org-mac-link-devonthink-app-p) + ("o" "utlook" org-mac-link-outlook-message-insert-selected org-mac-link-outlook-app-p) + ("a" "ddressbook" org-mac-link-addressbook-item-insert-selected org-mac-link-addressbook-app-p) + ("s" "afari" org-mac-link-safari-insert-frontmost-url org-mac-link-safari-app-p) + ("f" "irefox" org-mac-link-firefox-insert-frontmost-url org-mac-link-firefox-app-p) + ("v" "imperator" org-mac-link-vimperator-insert-frontmost-url org-mac-link-firefox-vimperator-p) + ("c" "hrome" org-mac-link-chrome-insert-frontmost-url org-mac-link-chrome-app-p) + ("C" "hromium" org-mac-link-chromium-insert-frontmost-url org-mac-link-chromium-app-p) + ("b" "rave" org-mac-link-brave-insert-frontmost-url org-mac-link-brave-app-p) + ("e" "evernote" org-mac-link-evernote-note-insert-selected org-mac-link-evernote-app-p) + ("t" "ogether" org-mac-link-together-insert-selected org-mac-link-together-app-p) + ("S" "kim" org-mac-link-skim-insert-page org-mac-link-skim-app-p) + ("A" "crobat" org-mac-link-acrobat-insert-page org-mac-link-acrobat-app-p) + ("q" "utebrowser" org-mac-link-qutebrowser-insert-frontmost-url org-mac-link-qutebrowser-app-p))) + + ;;;###autoload (defun org-mac-link-get-link (&optional beg end) "Prompt for an application to grab a link from. @@ -246,29 +279,13 @@ is active, that will be the link's description." (if (use-region-p) (list (region-beginning) (region-end)) '())) - (let* ((descriptors - `(("F" "inder" org-mac-link-finder-insert-selected ,org-mac-link-finder-app-p) - ("m" "ail" org-mac-link-mail-insert-selected ,org-mac-link-mail-app-p) - ("d" "EVONthink Pro Office" org-mac-link-devonthink-item-insert-selected - ,org-mac-link-devonthink-app-p) - ("o" "utlook" org-mac-link-outlook-message-insert-selected ,org-mac-link-outlook-app-p) - ("a" "ddressbook" org-mac-link-addressbook-item-insert-selected ,org-mac-link-addressbook-app-p) - ("s" "afari" org-mac-link-safari-insert-frontmost-url ,org-mac-link-safari-app-p) - ("f" "irefox" org-mac-link-firefox-insert-frontmost-url ,org-mac-link-firefox-app-p) - ("v" "imperator" org-mac-link-vimperator-insert-frontmost-url ,org-mac-link-firefox-vimperator-p) - ("c" "hrome" org-mac-link-chrome-insert-frontmost-url ,org-mac-link-chrome-app-p) - ("b" "rave" org-mac-link-brave-insert-frontmost-url ,org-mac-link-brave-app-p) - ("e" "evernote" org-mac-link-evernote-note-insert-selected ,org-mac-link-evernote-app-p) - ("t" "ogether" org-mac-link-together-insert-selected ,org-mac-link-together-app-p) - ("S" "kim" org-mac-link-skim-insert-page ,org-mac-link-skim-app-p) - ("A" "crobat" org-mac-link-acrobat-insert-page ,org-mac-link-acrobat-app-p) - ("q" "utebrowser" org-mac-link-qutebrowser-insert-frontmost-url ,org-mac-link-qutebrowser-app-p))) + (let* ((descriptors org-mac-link-descriptors) (menu-string (make-string 0 ?x)) input) ;; Create the menu string for the keymap (mapc (lambda (descriptor) - (when (elt descriptor 3) + (when (eval (elt descriptor 3)) ;eval needed to reload latest predicate values (setf menu-string (concat menu-string "[" (elt descriptor 0) "]" (elt descriptor 1) " ")))) @@ -280,7 +297,7 @@ is active, that will be the link's description." (setq input (read-char-exclusive)) (mapc (lambda (descriptor) (let ((key (elt (elt descriptor 0) 0)) - (active (elt descriptor 3)) + (active (eval (elt descriptor 3))) ;eval needed to reload latest predicate values (grab-function (elt descriptor 2))) (when (and active (eq input key)) (if (and beg end) @@ -459,6 +476,42 @@ The links are of the form ::split::." (insert (org-mac-link-chrome-get-frontmost-url))) + +;;; Handle links from Chromium.app +;; Grab the frontmost url from Chromium. Same limitations as +;; Firefox because Chrome doesn't publish an Applescript dictionary + +(defun org-mac-link-applescript-chromium-get-frontmost-url () + "AppleScript to get the links to the frontmost window of the Chromium.app." + (let ((result + (org-mac-link-do-applescript + (concat + "set frontmostApplication to path to frontmost application\n" + "tell application \"Chromium\"\n" + " set theUrl to get URL of active tab of first window\n" + " set theResult to (get theUrl) & \"::split::\" & (get name of window 1)\n" + "end tell\n" + "activate application (frontmostApplication as text)\n" + "set links to {}\n" + "copy theResult to the end of links\n" + "return links as string\n")))) + (replace-regexp-in-string + "^\"\\|\"$" "" (car (split-string result "[\r\n]+" t))))) + +;;;###autoload +(defun org-mac-link-chromium-get-frontmost-url () + "Get the link to the frontmost window of the Chromium.app." + (interactive) + (message "Applescript: Getting Chromium url...") + (org-mac-link-paste-applescript-links (org-mac-link-applescript-chromium-get-frontmost-url))) + +;;;###autoload +(defun org-mac-link-chromium-insert-frontmost-url () + "Insert the link to the frontmost window of the Chromium.app." + (interactive) + (insert (org-mac-link-chromium-get-frontmost-url))) + + ;;; Handle links from Brave.app ;; Grab the frontmost url from Brave. Same limitations as @@ -923,20 +976,20 @@ note(s) in Evernote.app and make a link out of it/them." -;;; Handle links from DEVONthink Pro Office.app +;;; Handle links from DEVONthink*.app (org-link-set-parameters "x-devonthink-item" :follow #'org-mac-link-devonthink-item-open) (defun org-mac-link-devonthink-item-open (uid _) - "Open UID, which is a reference to an item in DEVONthink Pro Office." + "Open UID, which is a reference to an item in DEVONthink*.app." (shell-command (concat "open \"x-devonthink-item:" uid "\""))) (defun org-mac-link-applescript-get-selected-devonthink-item () - "AppleScript to create links to selected items in DEVONthink Pro Office.app." + "AppleScript to create links to selected items in DEVONthink*.app." (org-mac-link-do-applescript (concat "set theLinkList to {}\n" - "tell application \"" org-mac-link-devonthink-app-name "\"\n" + "tell application id \"DNtp\" \n" "set selectedRecords to selection\n" "set selectionCount to count of selectedRecords\n" "if (selectionCount < 1) then\n" @@ -953,18 +1006,18 @@ note(s) in Evernote.app and make a link out of it/them." "return theLinkList as string"))) (defun org-mac-link-devonthink-get-links () - "Create links to the item(s) currently selected in DEVONthink Pro Office. + "Create links to the item(s) currently selected in DEVONthink*.app. This will use AppleScript to get the `uuid' and the `name' of the -selected items in DEVONthink Pro Office.app and make links out of it/them. +selected items in DEVONthink*.app and make links out of it/them. This function will push the Org-syntax text to the kill ring, and return it." (message "Org Mac DEVONthink: looking for selected items...") (org-mac-link-paste-applescript-links (org-mac-link-applescript-get-selected-devonthink-item))) ;;;###autoload (defun org-mac-link-devonthink-item-insert-selected () - "Insert a link to the item(s) currently selected in DEVONthink Pro Office. + "Insert a link to the item(s) currently selected in DEVONthink*.app. This will use AppleScript to get the `uuid'(s) and the name(s) of the -selected items in DEVONthink Pro Office and make link(s) out of it/them." +selected items in DEVONthink*.app and make link(s) out of it/them." (interactive) (insert (org-mac-link-devonthink-get-links))) -- 2.47.3