From: Malcolm Matalka <mmatalka@gmail.com>
To: Marcin Borkowski <mbork@mbork.pl>
Cc: emacs-orgmode@gnu.org
Subject: Re: Tracking time from one state to another?
Date: Thu, 18 Apr 2019 17:34:17 +0200 [thread overview]
Message-ID: <86zhoncop2.fsf@gmail.com> (raw)
In-Reply-To: <878sw7ix52.fsf@mbork.pl>
[-- Attachment #1: Type: text/plain, Size: 2728 bytes --]
Marcin Borkowski <mbork@mbork.pl> writes:
> On 2019-04-17, at 14:20, Malcolm Matalka <mmatalka@gmail.com> wrote:
>
>> Hello,
>>
>> Is it possible in org-mode to track, and report, the duration of certain
>> state transitions in org-mode? In particular, I'm interested in
>> tracking how long it takes me to go from a state that means I'm actively
>> working on an item to it being in a done state?
>>
>> In my case, an item might go from working, to waiting, to working, to
>> done. And in this case I'm only really interested in the last working
>> to done time.
>>
>> For my case, I'm looking to do a weekly report on how long it takes me
>> to complete tasks that I have said I will work on.
>
> Hi Malcolm,
>
> that sounds interesting. Since you can turn on logging of state changes
> (as you probably know), this is in principle possible, though I don't
> think it is built in.
>
> I guess writing a bit of Elisp to accomplish this should not be very
> difficult, though it seems that currently the problem is a bit
> underspecified. If you could elaborate, e.g., provide an example of
> your state change log and describe the result you would like to get,
> I could be tempted to coding this.
>
> Best,
Sure!
So for my use case, I'm mostly interested in the last transition to a
finished state, but for simplicity I'll specify the two states I'm
interested in:
Given states NEXT and DONE, I want to know the time between going into
NEXT and over to DONE.
For example, given the following logbook:
:LOGBOOK:
- State "DONE" from "NEXT" [2019-04-01 Mon 11:07]
- State "NEXT" from "TODO" [2019-04-01 Mon 10:35]
- State "NEXT" from "TODO" [2018-07-02 Mon 11:03]
:END:
This item would be 32 minutes.
This one:
:LOGBOOK:
- State "DONE" from "NEXT" [2019-04-10 Wed 09:56]
- State "NEXT" from "WAITING" [2019-04-10 Wed 09:40]
- State "WAITING" from "NEXT" [2019-04-09 Tue 10:44]
- State "NEXT" from "WAITING" [2019-04-09 Tue 10:10]
- State "WAITING" from "NEXT" [2019-04-08 Mon 16:39]
- State "NEXT" from "TODO" [2019-04-08 Mon 11:14]
:END:
Would be 16 minutes.
I'd like to specify what time range to do this for, and be able to sort
by duration.
I think a dynamic block, like clocktable, would probably be a fine.
Any idea what the level of work involved is to accomplish this? I'm
guessing a very hacky version might be to modify clock table and look at
the logbook instead of clock and filter out all but the last transition?
Also, this is just the usecase I'm interested in, so if you have
thoughts on what a more general form would look like, that would be interested.
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 487 bytes --]
next prev parent reply other threads:[~2019-04-18 15:34 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-04-17 12:20 Tracking time from one state to another? Malcolm Matalka
2019-04-18 11:25 ` Marcin Borkowski
2019-04-18 15:34 ` Malcolm Matalka [this message]
2019-04-19 4:37 ` Marcin Borkowski
2019-04-20 18:55 ` Julius Dittmar
2019-04-22 14:09 ` Malcolm Matalka
2019-04-22 14:27 ` Ken Mankoff
2019-04-23 6:07 ` Malcolm Matalka
2019-04-23 6:32 ` Ken Mankoff
2019-04-23 9:00 ` Malcolm Matalka
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=86zhoncop2.fsf@gmail.com \
--to=mmatalka@gmail.com \
--cc=emacs-orgmode@gnu.org \
--cc=mbork@mbork.pl \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.