Questions about Emacs+Org Roam

Hello! I’m considering getting into Emacs for knowledge management and note-taking using org-mode and org-roam and see how it compares to Obsidian.

I have three questions:

  1. How can I use Emacs on mobile and sync across all of my devices? I need cross-platform usability, especially since I plan to use it on both my iPhone and iPad. I’ve tried Beorg, but it seems like it’s only for task management.
  2. How can I integrate it with modern apps and services (e.g. Readwise)? This is something that Obsidian has, which I want to implement in Emacs if it’s possible. This would be especially helpful for org-roam.
  3. What does Emacs (in combination with org-mode and org-roam) have that Obsidian doesn’t? Has anyone here switched from Obsidian to Emacs?

Thanks!

Hi.

I use Github to sync Org-Roam between different computers (as in: Macs). You can edit files through all the usual means on iOS / iPadOS - there is, for example, the excellent working copy - but to my knowledge there is no way to replicate org-roam (the database and backlinking) on mobile. To capture “fleeting notes”, I use Drafts on iOS and iPadOs. I add these to org-roam when I am back at my Mac.

There are some weird hacks around for some of these services. But you probably would not be satisfied with these solutions and it will take you a lot of time (we are talking months here, if you are beginner to Emacs) to get this working.

Pros: Emacs can be hacked to perfectly suit your needs, probably more than Obsidian ever can. I have keyboard shortcuts that allow me to jump from link to link, Chinese dictionaries and a design that I want. Cons: Out of the box almost nothing works as expected (if you are used to software developed in the last 20 years ;). Emacs has a steep learning curve but is rewarding in the long run (for me, at least).

Honest question: why do you want to switch?

1 Like

Interesting discussion on Reddit (I believe it’s you).

I’m also inclined to say that if your core part of workflow is Apple Watch (dictation with Drafts), iPhone, and iPad, you will likely struggle to incorporate Emacs and Org files into it.

I made my own Org-roam plug-in to work with md files to better integrate with my iPhone and iPad. It’s not updated to keep up with new stuff in the Org-roam ecosystem, so it’s on hold at the moment.

I also use Drafts. It’s a crucial part of my workflow. I can instantly dictate notes and/or ideas on my Apple Watch with it, and sync it with Obsidian. It removes so much friction.

Yeah, that page only mentions Readwise in ‘other tools’.

Does it also take a lot of time to maintain Emacs when you get everything up and running? While I am someone that loves tinkering, I don’t want to spend more time getting things to work* than actually working after the initial, necessary “tinkering hump”.

It’s not a switch from Obsidian to Emacs for me. I haven’t really used Obsidian much.

I want to try Emacs because:

Indeed it is :smiley:

I see. Is there any alternative to quickly capture notes/ideas in Emacs like you can with Drafts?

Where can I find it? Or is it not public?

For Drafts to Emacs / Org-Roam the way is not too far and I am sure you could built a custom export function for Drafts.

Readwise has Markdown export. You could either hack org-roam to use Markdown or built a Pandoc-based script. The only / main downside would be that your notes do not stay in sync. I personally use Zotero to store documents and then link these documents in my org-roam notes.

Paraphrasing a popular joke: Emacs is a great OS with a horrible text editor. Learning Emacs was one of my pandemic projects and it took several weeks/months to get to a point where I wasn’t changing my .emacs (the configuration file) every other day. Now I am only changing it to play with org-roam v2 (a long story).

Here is one more thought on this. In comparison to Roam Research, Obsidian, Devonthink, Tinderbox and other options to create a PKM, Emacs and Org-roam will probably have the longest lifetime. There are no proprietary formats and no commercial interests (which also has its downsides). However, it is my hope that Emacs is the last tool for PKM that I am learning.

Just as an idea, which is also related to the sync question, I believe:

I have used iOS’s Shortcuts app to create my own automatic workflow from dictating to the built-in Notes app. I sync’ed the file with iCloud to my (Windows) machine. In the end, what you will get is a text file (formatted to markdown, org, or something else). I don’t know if Drafts is really markdown-only app or deal with any text file, but it may not matter.

What I did was to create an expense entry for plaintext personal accounting. Every time I spent some money on the go, I would talk to my iPhone to create an expense entry (and balance it with either cash, debit card, or credit card account). I don’t do this any more but technically, it was a great system :wink:

After the initial entry is created via the dictation, when you have time to sit and think in front of a computer, you can edit it / move it to the right notes file in Emacs or Obsidian.

I preferred markdown format just because I would also edit the notes sync’ed between my iPad/iPhone and Windows. At the moment, I am not doing this (I’m not editing notes purely due to lack of time and/or lack of discipline).

Here. There is V2 branch – It does not work for the current commit of Org-roam.

For this, you might like to look at how Org-roam-ui is doing it. I think by “modern” it’s implied that it’s a web application, probably written in a JavaScript framework. ORUI is a React app. I think it uses a parser for Org file and turn it into JSON format, and then do its own stuff on React. Please have a look yourself; I am no developer.

Once you can get JSON out of Org file, then I’m guessing it will be a question of the end-point’s API – how Readwise works with inbound requests. You might prefer to have a separate CLI program to deal with HTTP requests, or maybe do it within Emacs. I have a feeling writing a CLI program with Node might be easier, especially (likely) authentication with OAuth, etc. But not sure really.

Logseq supports org files. It’s like Obsidian but on the browser. They dont have a mobile app yet but you can use it via Safari. It can auto push pull to github too.

Their demo site

Integrating org-roam (v1) and logseq

Do you use it? Does it work for you? I was a bit amazed to find out how well org is supported just by the regular github page (see the example below). Even links work (that is for v1).

BetterVessel:

I second what has been said about the length of time that it takes to learn Emacs. You cannot master it in a weekend. I had tried several times before but did not stick with it because I had other alternatives.

I tried again in April to explore org-roam V1, but I drifted away in May. I came back in August to implement Getting Things Done with org-mode. I was pleased to find org-roam V2 available and easy to migrate to. The org-roam-ui is very useful for finding duplicate nodes and other mishaps. The 3D view of the network is also very impressive.

I stumbled into the journaling capability of Emacs and have been using it daily. I am starting to train myself to open files with Emacs rather than TextMate. I am on a 75-day streak in my current run with Emacs, and I am convinced that it is worth the effort. My GTD efforts with Agenda are on hold as I bring order to other aspects of my computing environment.

If you can find enough reasons to use Emacs, you will stick with it. The powerful autocompletion and suggestion systems like helm and ivy make it easier to stumble into the correct command.

I have hit steady states in terms of configuring other editors (e.g., Vim and neovim) and expect to do so with Emacs eventually once I have explored the packages on my wish list. Must-have packages should include awesome-tabs.

One tip from Dr. Paul A. Johnson (https://pj.freefaculty.org/guides/Rcourse/emacs-ess/emacs-ess.pdf) is not to fear using the pull-down menus. You can get a lot done in Emacs by knowing only a handful of key-bindings and using the pull-down menus.

1 Like

Coming from a macOS background, I also have a section in my .emacs to make keyboard bindings more “sane” (and another one to “prettify” the whole desktop). Fun fact: macOS itself actually uses some of the Emacs bindings.

In case somebody is wondering about the particularities of my setup:

(setq mac-command-modifier 'super
    mac-option-modifier 'meta
    mac-function-modifier 'hyper
    mac-right-option-modifier 'none
  default-input-method "MacOSX")

  (global-set-key (kbd "M-<right>") 'right-word)
  (global-set-key (kbd "M-<left>") 'left-word)
  (global-set-key (kbd "M-<up>") 'org-backward-paragraph)
  (global-set-key (kbd "M-<down>") 'org-forward-paragraph)
  (global-set-key (kbd "C-<up>") 'org-metaup)
  (global-set-key (kbd "C-<down>") 'org-metadown)
  (global-set-key (kbd "C-<right>") 'org-metaright)
  (global-set-key (kbd "C-<left>") 'org-metaleft)
  (define-key org-mode-map (kbd "M-<right>") nil)
  (define-key org-mode-map (kbd "M-<left>") nil)
  (define-key org-mode-map (kbd "M-<up>") nil)
  (define-key org-mode-map (kbd "M-<down>") nil)
  (global-set-key "\C-cl" 'org-store-link)
  (global-set-key "\C-ca" 'org-agenda)
  (global-set-key "\C-cc" 'org-capture)
  (global-set-key "\C-cb" 'org-iswitchb)  
  (global-set-key (kbd "s-r") 'helm-rg)


  (global-set-key (kbd "s-=") 'scale-up-font)
  (global-set-key (kbd "s--") 'scale-down-font)
  (global-set-key (kbd "s-0") 'reset-font-size)
  (global-set-key (kbd "s-q") 'my-quit)
  (global-set-key (kbd "s-v") 'yank)
  (global-set-key (kbd "s-c") 'kill-ring-save)
  (global-set-key (kbd "s-a") 'mark-whole-buffer)
  (global-set-key (kbd "s-x") 'kill-region)
  (global-set-key (kbd "s-w") 'delete-window)
  (global-set-key (kbd "s-W") 'delete-frame)
  (global-set-key (kbd "s-n") 'make-frame)
  (global-set-key (kbd "s-z") 'undo)
  (global-set-key (kbd "s-<right>") 'end-of-visual-line)
  (global-set-key (kbd "s-<left>") 'beginning-of-visual-line)
  (global-set-key (kbd "s-<up>") 'beginning-of-buffer)
  (global-set-key (kbd "s-<down>") 'end-of-buffer)
  (global-set-key (kbd "s-<return>") 'org-meta-return)

(global-set-key (kbd "s-<") 'org-roam-dailies-capture-today)
(global-set-key (kbd "s->") 'org-roam-dailies-find-today)


(global-set-key (kbd "M-s-<right>") 'org-next-link)
(global-set-key (kbd "M-s-<left>") 'org-previous-link)
(global-set-key (kbd "M-s-<down>") 'org-open-at-point)
(global-set-key (kbd "M-s-<up>") 'previous-buffer)
(global-set-key (kbd "S-s-<return>") 'org-insert-heading)

loatang:

Thank you for sharing your sane key bindings for the Mac. I like your use of the command key as the super key!

I would be interested in your ``prettfiy’’ settings.

Sure :wink:

; the basics
(setq inhibit-splash-screen t)
(display-time-mode t)
(delete-selection-mode t) ;; instant replace
(tool-bar-mode 0) ;; no gui toolbar

; one frame, two windows 
(split-window-right)
(setq initial-frame-alist '((top . 50) (left . 145) (width . 165) (height . 60)))

; better scrolling
(use-package smooth-scroll
  :config
  (smooth-scroll-mode 1)
  (setq smooth-scroll/vscroll-step-size 5)
  )
(require 'smooth-scrolling)

; Mac-specific
(setq ns-pop-up-frames t)
(advice-add 'mwheel-scroll :before (lambda (arg) (if (not (eq last-command 'mwheel-scroll)) (setq point-before-mwheel-scroll (window-point)))))
(defun jump-back () (goto-char point-before-mwheel-scroll))

; I really like the Zenburn theme
(load-theme 'zenburn t)
(transient-mark-mode 1) ;; Enable transient mark mode
(setq-default line-spacing 0.15)
(global-visual-line-mode 1)
(setq org-export-coding-sytsem 'utf-8)

; Don’t assume that sentences should have two spaces after periods.
(setq sentence-end-double-space nil)

; Chinese fonts
(require 'cnfonts)
(cnfonts-enable)
(setq cnfonts-use-face-font-rescale t)

; org mode emphasis in khaki
(add-to-list 'org-emphasis-alist
 '("/" (italic :foreground "khaki")
))

; Underline line at descent position, not baseline position
(setq x-underline-at-descent-line t)

; if you have a two window setup, you want sensible window splitting
(setq split-height-threshold 100
      split-width-threshold 160)

(defun my-split-window-sensibly (&optional window)
    "replacement `split-window-sensibly' function which prefers vertical splits"
    (interactive)
    (let ((window (or window (selected-window))))
        (or (and (window-splittable-p window t)
                 (with-selected-window window
                     (split-window-right)))
            (and (window-splittable-p window)
                 (with-selected-window window
                     (split-window-below))))))

(setq split-window-preferred-function #'my-split-window-sensibly)

How?

Do you think anyone will be working on that in the future?

I’ve seen this around a lot. But I don’t really understand what it means.

Can you elaborate?

What are the downsides?

That’s very interesting. If you don’t mind me asking, why did you stop using your system?

Thank you!

Thanks. Thomas actually replied to my Reddit post and gave his input which was really nice.

I don’t know what half the things here even are :sweat_smile:

One of the things about Emacs is that it’s not beginner-friendly to learn. A lot of the material assumes at least some basic knowledge. There are no step-by-step holistic guides that pertain to beginners for knowledge management in Emacs, like there are for Obsidian. Examples of people who make such guides/courses are Linking Your Thinking (LYT) on YouTube and Santi Younger.

Quote from one of my Reddit posts:

"I am interested in learning Emacs, but finding material about knowledge management related to Emacs is pretty hard, let alone learning Emacs itself.

If someone could create a paid, step-by-step course teaching Emacs that also involves how to set it up for knowledge management and task management, I would probably buy it in a heartbeat.

But it doesn’t seem like such a thing exists. Until it does (if ever), I might hold off on Emacs.

It’s a potential business idea. I think that there’s a market for such a course. From what I’ve seen, there are many people like myself who have virtually no programming background, are interested in knowledge management, task management, extensibility, and freedom, but get overwhelmed with how complex Emacs is."

Yeah. I use Logseq and plan to use it in tandem with Obsidian as they both run on markdown. The only issue is that I wouldn’t be able to integrate org-roam as it runs on org files.

@bmooers1 What were your alternatives?

What does that do?

You can do so yourself. It is actually pretty easy. Go to the settings of Drafts and:

Here you can format your import to Drafts in a custom way:

Notes created in this format can easily copied & pasted into org-roam:

Out of the box Emacs (imho) is a terrible editor. Textmate, Sublime and others do have more advanced features and are more accessible. However, no other editor (that I know of) may serve in a similar manner as a platform for other software to run on. Emacs also gives you a tremendous amount of freedom to run code that changes its own behaviour. Obsidian has plugins that go a long way but it comes nowhere near Emacs.

When I started out with Emacs last year (a pandemic project), I tried a lot of things. Turns out that you totally can read email or PDFs in Emacs - but maybe not necessarily want to.

I wrote about it here. Basically, v2 does not add anything for me (yet) - but breaks some parts of my workflow (now in particular org-roam-graph). Occasionally I play around with v2, improve my setup and then return to my previous setup (via git).

No one is paid to help you. No one benefits financially from bug-free and stable software. If there are enough people that have an interest in maintaining your software: great. But what happens, if the sole programmer of your main software loses his/her interest in the project? Btw the core of Obsidian has been coded only by two people, right?

It’s nothing to do with the system. I can’t seem to keep doing personal finance more than a few months at a time. I had tried more than 3 times in my life before this last time; it never stuck with me.

I am not a programmer. My academic background is humanities. I have tried different text editors but keep coming back to Emacs (after periods of disuse).

For what it’s worth, I found my notes from 8th January 2013 when I was transitioning to Emacs for the first time. I will add an unabridged copy below – apparently written in markdown; no screen shots survived ← looking back, I probably didn’t take a screen shot but wrote the note within that “zen” screen within Emacs.

For the source of inspiration that got me started with Emacs, the author has since updated the whole paper to a website and booklet available at https://plain-text.co/.

Here is a good quote from it that might help you and encourage you to read the booklet.

Good luck with finding your own way.

although in what follows I advocate you take a look at several applications in particular, it’s not really about the gadgets or utilities. The Zen of Organization is not to be found in Fancy Software. Nor shall the true path of Getting Things Done be revealed to you through the purchase of a nice Moleskine Notebook. Instead, it lies within—unfortunately.

Unabridged copy of my note from 2013

Filiname: 20130108_N_transition_to_emacs

# Transtion to Emacs on Mac OS X

- Famous screen cast may help, but probably not mandatory. The
  tutorial on the org website [[need reference]] and the tutorial
  inside Emacs is good -- though you may not be able to invoke it when
  you first launch Emacs for the first time.

- Key binding is not intuitive - now the arrow keys seem to be rather
  norm...
  
- Spent a whole day and night to get the screen right for me..

- But look at this, a clean "zen" screen is possible with Emacs.

- Hmm... Customisation takes a lot time and efforts -- it is not a
  trivial subject.


- Genesis: inspired by this: e source file for this document is available at https://github.com/kjhealy/workflow-paper

- Great and simple tutorials for beginners. These are not just for Org-mode, I don't think. They are helpful to learn basics of Emacs to get over the initial hump.
 
 -  http://orgmode.org/worg/org-tutorials/orgtutorial_dto.html
 - [http://orgmode.org/worg/org-tutorials/org4beginners.html](Org-mode beginning at the basics)
 - [http://orgmode.org/worg/org-configs/org-customization-guide.html](Org customization guide for beginners)
1 Like

Just found this thread, and wanted to shoutout @nobiot 's excellent md-roam which now makes it possible to use markdown files with org-roam v2! org-roam-ui also has support for previewing these files.

I think this is a great step into making emacs more interoperable with other systems, and can provide a nice way to “ease” into the emacs ecosystem.

1 Like

it’s 2024, is it possible to integrate emacs roam with Readwise now?