Wanting to know how many days it will take to reach a date is so human. Here's a post to show how you can do this in Emacs.
http://yummymelon.com/devnull/computing-days-until-with-emacs.html
Wanting to know how many days it will take to reach a date is so human. Here's a post to show how you can do this in Emacs.
http://yummymelon.com/devnull/computing-days-until-with-emacs.html
@kickingvegas TIL. I had no idea Org had such a function, but of course it does..
Inspired by this I whipped up a quick embark action for calling it on an Org timestamp:
(defun viiru/embark-timestamp-to-now (ts)
"Display and kill difference between timestamp and today."
(interactive "sTimestamp: ")
(let ((res (format "%d" (org-timestamp-to-now ts))))
(message "Difference is %s days" res)
(kill-new res)))
(defvar-keymap embark-org-timestamp-map
:doc "Embark actions for org timestamps."
:parent embark-general-map
"t" #'org-toggle-timestamp-type
"d" #'viiru/embark-timestamp-to-now)
(add-to-list 'embark-keymap-alist '(org-timestamp . embark-org-timestamp-map))