From e93c77f6a59fd0f58a83dbdbbe526a2a0820aa48 Mon Sep 17 00:00:00 2001 From: Marco Luca Sbodio Date: Mon, 1 Jul 2024 18:50:40 +0100 Subject: [PATCH] (docs): add details about org-roam-protocol with Homebrew (#2441) Add additional information for setting up org-roam-protocol on Mac OS when using emacs installed from Homebrew (see also https://org-roam.discourse.group/t/problem-with-org-roam-protocol/3473) --- doc/org-roam.org | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/doc/org-roam.org b/doc/org-roam.org index fdb74a0..cc209de 100644 --- a/doc/org-roam.org +++ b/doc/org-roam.org @@ -1106,6 +1106,21 @@ defaults write com.apple.LaunchServices/com.apple.launchservices.secure LSHandle Then restart your computer. +If you're using the [[https://formulae.brew.sh/formula/emacs][Emacs Homebrew formula]], you may need one of the following additional configurations: + +a) Add option `-c` to `emacsclient` in the script, and start emacs from command line with `emacs --daemon` + +#+begin_src emacs-lisp + on open location this_URL + set EC to "/usr/local/bin/emacsclient -c --no-wait " + set filePath to quoted form of this_URL + do shell script EC & filePath & " &> /dev/null &" + tell application "Emacs" to activate + end open location +#+end_src + +b) Add `(server-start)` in .emacs (in this case you do not need option `-c` for `emacsclient` in the script, and you do not need to start emacs with `emacs --daemon` + ***** Testing org-protocol To test that you have the handler setup and registered properly from the command