lisp/org.el: Add `org-after-note-stored-hook'
* lisp/org.el: Add `org-after-note-stored-hook' which is called at the end of the `org-store-log-note' function. * etc/ORG-NEWS: Document the new hook. TINYCHANGE
This commit is contained in:
parent
0ebb36caea
commit
f3e306c737
|
@ -735,6 +735,10 @@ any more. Run ~org-ctags-enable~ to setup hooks and advices:
|
|||
#+end_src
|
||||
|
||||
** New and changed options
|
||||
*** New hook ~org-after-note-stored-hook~
|
||||
|
||||
This new hook runs when a note has been stored.
|
||||
|
||||
*** New option controlling how Org mode sorts things ~org-sort-function~
|
||||
|
||||
Sorting of agenda items, tables, menus, headlines, etc can now be
|
||||
|
|
|
@ -1990,6 +1990,13 @@ Lisp variable `org-state'."
|
|||
:group 'org-todo
|
||||
:type 'hook)
|
||||
|
||||
(defcustom org-after-note-stored-hook nil
|
||||
"Hook triggered after a note is stored.
|
||||
The point is at the stored note when the hook is executed."
|
||||
:group 'org-progress
|
||||
:type 'hook
|
||||
:package-version '(Org . "9.7"))
|
||||
|
||||
(defvar org-blocker-hook nil
|
||||
"Hook for functions that are allowed to block a state change.
|
||||
|
||||
|
@ -10846,6 +10853,7 @@ items are State notes."
|
|||
(unless (string-empty-p line)
|
||||
(indent-line-to ind)
|
||||
(insert-and-inherit line))))
|
||||
(run-hooks 'org-after-note-stored-hook)
|
||||
(message "Note stored")
|
||||
(org-back-to-heading t))))))
|
||||
;; Don't add undo information when called from `org-agenda-todo'.
|
||||
|
|
Loading…
Reference in New Issue