[Emacs] Simpler hook for org-unique-id
This commit is contained in:
parent
2e20b9594c
commit
52c23fb47c
@ -4608,14 +4608,7 @@ meaningful IDs for its headings. I actually wrote a package for this!
|
|||||||
:repo "Phundrak/org-unique-id")
|
:repo "Phundrak/org-unique-id")
|
||||||
:defer t
|
:defer t
|
||||||
:after org
|
:after org
|
||||||
:init
|
:init (add-hook 'before-save-hook #'org-unique-id-maybe))
|
||||||
(add-hook 'org-mode-hook
|
|
||||||
(lambda ()
|
|
||||||
(add-hook 'before-save-hook
|
|
||||||
(lambda ()
|
|
||||||
(when (and (eq major-mode 'org-mode)
|
|
||||||
(eq buffer-read-only nil))
|
|
||||||
(org-unique-id)))))))
|
|
||||||
#+end_src
|
#+end_src
|
||||||
|
|
||||||
*** Capture
|
*** Capture
|
||||||
|
Loading…
Reference in New Issue
Block a user