mirror of
https://github.com/doomemacs/doomemacs
synced 2025-08-01 12:17:25 -05:00
fix(org): save-buffer more selectively after org-refile
Fixing interop between this hook and org-reminders (or other org packages affected by the side-effects of `save-buffer`).
This commit is contained in:
@ -433,7 +433,10 @@ I like:
|
||||
|
||||
;; Fix #462: when refiling from org-capture, Emacs prompts to kill the
|
||||
;; underlying, modified buffer. This fixes that.
|
||||
(add-hook 'org-after-refile-insert-hook #'save-buffer)
|
||||
(add-hook! 'org-after-refile-insert-hook
|
||||
(defun +org-save-buffer-after-capture-h ()
|
||||
(when (bound-and-true-p org-capture-is-refiling)
|
||||
(save-buffer))))
|
||||
|
||||
;; HACK Doom doesn't support `customize'. Best not to advertise it as an
|
||||
;; option in `org-capture's menu.
|
||||
|
Reference in New Issue
Block a user