Compare commits
No commits in common. "d1e3409e804d8d84c6fddbb50d7181a9def78d03" and "482cebea6804c7a9ec08f3b86afc1969a067b9ec" have entirely different histories.
d1e3409e80
...
482cebea68
@ -424,26 +424,19 @@ should not be clocked."
|
|||||||
|
|
||||||
This functions tries to clock into the interrupted task, the
|
This functions tries to clock into the interrupted task, the
|
||||||
parent task, or the default task, in that order and only when
|
parent task, or the default task, in that order and only when
|
||||||
available, respectively. Clock in to the interrupted task only
|
available, respectively. If none of these tasks is available,
|
||||||
if it is not closed yet.
|
interactively query the user for the next task to clock into."
|
||||||
|
|
||||||
If none of the listed tasks is available, interactively query the
|
|
||||||
user for the next task to clock into."
|
|
||||||
(when (and (not org-clock-clocking-in)
|
(when (and (not org-clock-clocking-in)
|
||||||
(not org-clock-resolving-clocks-due-to-idleness))
|
(not org-clock-resolving-clocks-due-to-idleness))
|
||||||
(let (parent-task)
|
(let ((parent-task (db/find-parent-task)))
|
||||||
(save-mark-and-excursion
|
(save-mark-and-excursion
|
||||||
(cond
|
(cond
|
||||||
((and (markerp org-clock-interrupted-task)
|
((and (markerp org-clock-interrupted-task)
|
||||||
(marker-buffer org-clock-interrupted-task)
|
(marker-buffer org-clock-interrupted-task))
|
||||||
(org-with-point-at org-clock-interrupted-task
|
;; interrupted task is set
|
||||||
(not (member (nth 2 (org-heading-components))
|
|
||||||
org-done-keywords))))
|
|
||||||
;; interrupted task is set and not closed yet, so let's clock in
|
|
||||||
;; there
|
|
||||||
(org-with-point-at org-clock-interrupted-task
|
(org-with-point-at org-clock-interrupted-task
|
||||||
(org-clock-in)))
|
(org-clock-in)))
|
||||||
((setq parent-task (db/find-parent-task))
|
(parent-task
|
||||||
;; found parent task
|
;; found parent task
|
||||||
(org-with-point-at parent-task
|
(org-with-point-at parent-task
|
||||||
(org-clock-in)))
|
(org-clock-in)))
|
||||||
@ -473,7 +466,7 @@ user for the next task to clock into."
|
|||||||
(modify-frame-parameters frame `((name . ,org-clock-heading)))))))
|
(modify-frame-parameters frame `((name . ,org-clock-heading)))))))
|
||||||
|
|
||||||
(defun db/show-current-org-task ()
|
(defun db/show-current-org-task ()
|
||||||
"Show title of currently clock in task in minibuffer."
|
"Show title of currently clock in task in modeline."
|
||||||
(interactive)
|
(interactive)
|
||||||
(message org-clock-current-task))
|
(message org-clock-current-task))
|
||||||
|
|
||||||
@ -823,11 +816,10 @@ PARAMS is a property list of the following parameters:
|
|||||||
|
|
||||||
(defun db/org-clock-in-last-task (&optional arg)
|
(defun db/org-clock-in-last-task (&optional arg)
|
||||||
;; from doc.norang.ca, originally bh/clock-in-last-task
|
;; from doc.norang.ca, originally bh/clock-in-last-task
|
||||||
"Clock into the last task from the clocking history.
|
"Clock in the interrupted task if there is one.
|
||||||
|
|
||||||
Skip the default task if it's at the top of the clocking history,
|
Skip the default task and get the next one. If ARG is given,
|
||||||
and get the next one. If ARG is given, forces clocking in of the
|
forces clocking in of the default task."
|
||||||
default task, though."
|
|
||||||
(interactive "p")
|
(interactive "p")
|
||||||
(let ((clock-in-to-task
|
(let ((clock-in-to-task
|
||||||
(cond
|
(cond
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user