Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- (defun org-remove-id-from-last-capture ()
- "Remove ID property from last `org-capture' entry, save capture buffer."
- (let* ((properties (org-entry-properties org-capture-last-stored-marker))
- (file (cdr (assoc "FILE" properties))))
- (when (org-entry-delete org-capture-last-stored-marker "ID")
- (with-current-buffer (get-file-buffer file)
- (save-buffer)))))
- (add-hook 'org-capture-after-finalize-hook #'org-remove-id-from-last-capture)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement