Move org-id-locations-file to org-directory

It makes more sense to store this file where you keep your org files,
rather than in Doom's .local files, which could be deleted for
debugging, or local only to a specific machine.

Also make ID links relative to org-directory, in case you use the same
org library on a different system with different filesystem
layout/system of symlinks.
This commit is contained in:
Henrik Lissner 2020-01-02 00:31:20 -05:00
parent 4d64021980
commit 13e2eefae1
No known key found for this signature in database
GPG key ID: 5F6C0EA160557395

View file

@ -933,11 +933,7 @@ compelling reason, so..."
(setq org-directory "~/org/" (setq org-directory "~/org/"
org-attach-id-dir ".attach/" org-attach-id-dir ".attach/"
org-publish-timestamp-directory (concat doom-cache-dir "org-timestamps/") org-publish-timestamp-directory (concat doom-cache-dir "org-timestamps/")
org-preview-latex-image-directory (concat doom-cache-dir "org-latex/") org-preview-latex-image-directory (concat doom-cache-dir "org-latex/"))
org-id-locations-file (concat doom-etc-dir "org-id-locations")
;; Global ID state means we can have ID links anywhere (required by
;; `org-brain')
org-id-track-globally t)
(defvar org-modules (defvar org-modules
'(;; ol-w3m '(;; ol-w3m
@ -1000,4 +996,10 @@ compelling reason, so..."
(run-hooks 'org-load-hook)) (run-hooks 'org-load-hook))
:config :config
;; Global ID state means we can have ID links anywhere. This is required for
;; `org-brain', however.
(setq org-id-track-globally t
org-id-locations-file (concat org-directory ".orgids")
org-id-locations-file-relative t)
(add-hook 'org-open-at-point-functions #'doom-set-jump-h)) (add-hook 'org-open-at-point-functions #'doom-set-jump-h))