Hi all,
Overview
I’ve successfully transitioned from org-roam v1 to v2 in my Doom Emacs environment. The conversion tool worked and everything except for org-protocol/capturing websites from Firefox is working.
Background
I have an Emacs environment based on Doom that’s used on multiple Macos and GNU/Linux workstations. I’ve followed the guide in the official documentation and in the past, this worked. I’m also using the correct Doom module flags AFAIK.
In my .doom.d/config.el I have:
(after! org-roam (require 'org-roam-protocol))
On all workstations, I was using the following bookmark in Firefox to capture webpages as roam nodes:
javascript:location.href = 'org-protocol://roam-ref?template=r&ref=' + encodeURIComponent(location.href) + '&title=' + encodeURIComponent(document.title) + '&body=' + encodeURIComponent(window.getSelection())
When I clicked this bookmark, Emacs would pop up with the org-roam capture buffer containing a link to the website and prompted me for a description. Everything was working well and I’d captured several hundred websites using this method.
Problem
Now, when I click this bookmark, Emacs is focused by the OS, but there’s no org-roam capture buffer and it’s as though I had simply alt-tabbed to the application. There’s no indication of an error in any Emacs buffers, so I suspect that something in the way mac and GNU/Linux registers the protocol has changed. Both OSes are affected across three workstations. Other usage of roam (and org) appears normal.
I’ve re-run through the instructions in the official documentation without any success.
Update
macos: I’ve modified the macos script (Org-roam User Manual) to use emacs
rather than emacsclient
and now capturing a page will bring up a new emacs instance with the following error in the minibuffer:
Directory '/Users/unlockd/org-protocol:/' does not exist! Create it? (y or n)
This suggests that the protocol is not properly handled by the OS. This SE post suggests that the instructions in the org-roam manual are the correct way to register a protocol handler, and I’m certain I’ve registered it appropriately following the instructions.
Can someone help me determine where the problem is and how to fix it?