diff options
Diffstat (limited to 'lisp/+org-capture.el')
-rw-r--r-- | lisp/+org-capture.el | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/lisp/+org-capture.el b/lisp/+org-capture.el index 6968657..ba036bd 100644 --- a/lisp/+org-capture.el +++ b/lisp/+org-capture.el | |||
@@ -3,6 +3,7 @@ | |||
3 | ;;; Code: | 3 | ;;; Code: |
4 | 4 | ||
5 | (require 'cl-lib) | 5 | (require 'cl-lib) |
6 | (require 'acdw) | ||
6 | ;; We don't require `org-capture' here because I'll have to require this library | 7 | ;; We don't require `org-capture' here because I'll have to require this library |
7 | ;; to init.el /before/ org-capture is fully needed. But I do need to declare | 8 | ;; to init.el /before/ org-capture is fully needed. But I do need to declare |
8 | ;; `org-capture-templates'. | 9 | ;; `org-capture-templates'. |
@@ -39,6 +40,10 @@ LIST is a symbol and defaults to `org-capture-templates'." | |||
39 | (set list (sort (symbol-value list) (lambda (a b) | 40 | (set list (sort (symbol-value list) (lambda (a b) |
40 | (string< (car a) (car b)))))) | 41 | (string< (car a) (car b)))))) |
41 | 42 | ||
43 | (defun +org-capture-sort-after-init (&optional list) | ||
44 | "Sort LIST with `+org-capture-sort' after Emacs init." | ||
45 | (+ensure-after-init #'+org-capture-sort)) | ||
46 | |||
42 | ;;;###autoload | 47 | ;;;###autoload |
43 | (defun +org-capture-templates-setf (key value &optional list sort-after) | 48 | (defun +org-capture-templates-setf (key value &optional list sort-after) |
44 | "Add KEY to LIST, using `setf'. | 49 | "Add KEY to LIST, using `setf'. |