branch: externals/iso-date commit fe8075fa1ab56afb1bf61187002defb642d0525b Author: Daniel Mendler <m...@daniel-mendler.de> Commit: Daniel Mendler <m...@daniel-mendler.de>
Embark integration - maybe move to a separate embark-iso-date? --- iso-date.el | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/iso-date.el b/iso-date.el index 18633d572b..657b977e1b 100644 --- a/iso-date.el +++ b/iso-date.el @@ -327,5 +327,21 @@ Returned dates are also in that format." (when (thing-at-point-looking-at iso-date-regexp 10) (cons (match-beginning 0) (match-end 0)))) +;;;; embark.el integration + +(eval-after-load 'embark + '(progn + (embark-define-thingatpt-target iso-date) + (defvar-keymap embark-iso-date-map + :parent embark-general-map + "RET" #'iso-date-show-calendar + "a" #'iso-date-show-org-agenda + "c" #'iso-date-show-calendar + "d" #'iso-date-show-diary + "f" #'iso-date-echo-difference + "p" #'iso-date-pretty-print) + (add-to-list 'embark-target-finders 'embark-target-iso-date-at-point) + (add-to-list 'embark-keymap-alist '(iso-date embark-iso-date-map)))) + (provide 'iso-date) ;;; iso-date.el ends here