config/default: rebind 'SPC n {c,C,n,S}'
'SPC n c' -> Toggle last org clock 'SPC n C' -> Cancel current org clock 'SPC n n' -> org-capture 'SPC n S' -> Search org-directory headings Closes #2043
This commit is contained in:
parent
cd158c5656
commit
6cf17b1237
2 changed files with 22 additions and 2 deletions
|
@ -273,6 +273,24 @@ If on a:
|
|||
(ignore-errors (org-promote)))
|
||||
((call-interactively #'self-insert-command))))
|
||||
|
||||
;;;###autoload
|
||||
(defun +org/toggle-clock (arg)
|
||||
"Toggles clock on the last clocked item.
|
||||
|
||||
Clock out if an active clock is running. Clock in otherwise.
|
||||
|
||||
If in an org file, clock in on the item at point. Otherwise clock into the last
|
||||
task you clocked into.
|
||||
|
||||
See `org-clock-out', `org-clock-in' and `org-clock-in-last' for details on how
|
||||
the prefix ARG changes this command's behavior."
|
||||
(interactive "P")
|
||||
(if (org-clocking-p)
|
||||
(if arg
|
||||
(org-clock-cancel)
|
||||
(org-clock-out))
|
||||
(org-clock-in-last arg)))
|
||||
|
||||
|
||||
;;; Folds
|
||||
;;;###autoload
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue