From mboxrd@z Thu Jan 1 00:00:00 1970 From: Malcolm Matalka Subject: Re: Tracking time from one state to another? Date: Tue, 23 Apr 2019 11:00:15 +0200 Message-ID: <86sgu9cd0g.fsf@gmail.com> References: <868sw8n7qm.fsf@gmail.com> <875zr66rol.fsf@geus3064linuxwsm.geus.dk> <86tvepckzz.fsf@gmail.com> <87imv55j0l.fsf@geus3064linuxwsm.geus.dk> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([209.51.188.92]:54711) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hIrHp-00053o-Fm for emacs-orgmode@gnu.org; Tue, 23 Apr 2019 05:00:26 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hIrHo-0001QE-0A for emacs-orgmode@gnu.org; Tue, 23 Apr 2019 05:00:21 -0400 Received: from mail-lj1-x22f.google.com ([2a00:1450:4864:20::22f]:43753) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hIrHn-0001Pd-NZ for emacs-orgmode@gnu.org; Tue, 23 Apr 2019 05:00:19 -0400 Received: by mail-lj1-x22f.google.com with SMTP id f18so12746797lja.10 for ; Tue, 23 Apr 2019 02:00:19 -0700 (PDT) In-reply-to: <87imv55j0l.fsf@geus3064linuxwsm.geus.dk> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: "Emacs-orgmode" To: Ken Mankoff Cc: emacs-orgmode@gnu.org Ken Mankoff writes: > Hi Malcom, > > I think we're talking about two different things here. When you change TODO state, the time of the change is recorded. This is what you're doing. > > Org also has a time-tracking feature that is totally separate. You can "clock in" and "clock out" of a task which starts and stops a timer. You can then generate reports about that timer. The timer can be activated regardless of the TODO state, but you could also have the timer start (clock in) every time you set the state to "WORKING_ON_IT" or "INPROGRESS", and the timer stop (clock out) whenever the task is in NEXT or WAITING state. > > Then you can generate a CLOCK REPORT for each task and sub-task, which > is the amount of time you actually worked on it (i.e. the amount of > time it spent in the WORKING_ON_IT state. Yes we're talking about different things. I do not want the total amount of time I worked on an item, in this case, I'm already tracking that by clocking in and out. I'm after the time it took to go from NEXT to DONE. In this case I'm trying to track the time an item is in queue, and not the time the item is worked on. > > This is a different workflow than your current one - it uses the Org clocking feature, not just the TODO status feature. > > -k. > > On 2019-04-23 at 08:07 +0200, Malcolm Matalka wrote... >> Ken Mankoff writes: >> >>> Hi Malcom, >>> >>> On 2019-04-17 at 14:20 +0200, Malcolm Matalka wrote... >>>> 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. >>> >>> Org doesn't have a built-in feature to turn on/off the clock when you >>> change state, as far as I know. But it has the opposite - you can >>> change state when you clock in or out of a task. >> >> I don't want to turn on/off the clock when I change state, I want to get >> a report on the time between certain state transitions. That >> information is stored in the LOGBOOK (assuming one has that turned on). >> >>> >>> See section 7 here https://writequit.org/denver-emacs/presentations/2017-04-11-time-clocking-with-org.html#helpful-things >>> >>> And/or maybe thread here w/ some code https://lists.gnu.org/archive/html/emacs-orgmode//2009-04/msg00315.html >>> >>> So perhaps you can achieve this by changing your workflow a bit. Instead of changing state, just clock in and have the state set to INPROGRESS. Clock otu and have it set to WAITING. When it is done, it may be a two-step process of setting to DONE and making sure the clock is stopped. >>> >>> Would this achieve what you're looking for? >> >> Unfortunately no. I need to track the total time I spend in a task for >> billing reasons, but what I'm interested in here is how quickly I >> complete a task when there are no blockers/dependencies. And the way >> that presents itself in my LOGBOOK is the time between the final >> transition from NEXT to DONE. Before that, a TODO can go from NEXT, to >> WAITING, and back and forth. >> >>> >>> -k.