config/doom: autosync org-roam properly

This commit is contained in:
xeruf 2021-11-23 12:54:33 +01:00
parent 497a99341c
commit 8ec9d188d8
1 changed files with 7 additions and 1 deletions

View File

@ -385,7 +385,13 @@ Version 2019-11-04 2021-02-16"
(when my/auto-org-roam-db-sync-mode
(run-with-idle-timer
my/auto-org-roam-db-sync--timer-interval :repeat
(and 'org-roam-db-sync 'org-roam-update-org-id-locations 'org-mode-restart)))))
#'my/org-roam-update))))
(defun my/org-roam-update ()
"Update org-roam database and sync ids to org if in org-mode"
(interactive)
(when (equal major-mode 'org-mode) (org-roam-db-sync) (let ((org-display-remote-inline-images 'skip)) (org-roam-update-org-id-locations)) (org-mode-restart)))
(my/auto-org-roam-db-sync-mode)
;; Prompt after idleness - Focused? ETC? (Pragmatic Programmer) - org-journal
)