Created
November 24, 2013 23:36
-
-
Save stephenwithav/7634002 to your computer and use it in GitHub Desktop.
Code to execute custom hooks before clocking out in org-mode. (save-excursion) fails to return me to the proper screen, e.g., the agenda.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defvar org-pre-clock-cancel-hook nil | |
"Hooks to run immediately before canceling a clock.") | |
(defun rand/org-clock-cancel () | |
(interactive) | |
(save-excursion | |
(org-clock-goto) | |
(run-hooks 'org-pre-clock-cancel-hook) | |
(org-clock-cancel))) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment