From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Sebastien Vauban" Subject: Re: starting a clock when not in org-mode Date: Fri, 13 May 2011 13:46:25 +0200 Message-ID: <80sjsin7qm.fsf@somewhere.org> References: <87k4dvc63u.fsf@ucl.ac.uk> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: 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-mXXj517/zsQ@public.gmane.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org-mXXj517/zsQ@public.gmane.org To: emacs-orgmode-mXXj517/zsQ@public.gmane.org Hi Eric, Eric S Fraga wrote: > Hello, > > I have been using the clocking features of org mode more and more as > time goes on. Brilliant feature. However, I am having problems with > one specific use case: > > The org-clock-in method works very well when I am pro-actively deciding > what tasks to work on, e.g. through the agenda view. However, in some > cases, I am reacting to external events (emails, somebody coming to see > me, phone call, etc). I have a number of tasks which are more general > and which capture this type of activity (admin, teaching, ...). If I > happen to be in an org mode buffer, then "C-u M-x org-clock-in RET" > allows me to pick the particular task (as it will typically be in the > history) and clock it in. Works well. > > If I am *not* in an org buffer (yes, this happens sometimes ;-), I > cannot do this as org-clock-in, even with the C-u arg, wants to find a > headline. Can anybody suggest how I can clock in to a previously > clocked task from any emacs mode? My solution is to use C-c C-x C-j, eventually with C-u prefix, from any Ema= cs buffer, thanks to: #+begin_src emacs-lisp (global-set-key (kbd "C-c C-x C-j") 'org-clock-goto) #+end_src This is sometimes bound locally by some modes. Then, I disable it locally: #+begin_src emacs-lisp ;; remove the binding of `C-c C-x', used by Org timeclocking commands (add-hook 'nxml-mode-hook (lambda () (define-key nxml-mode-map (kbd "C-c C-x") nil))) #+end_src > My current solution is to tag these general catch-all tasks > with :clocked:, use the agenda search (C-c a m clocked), select the > appropriate one and start the clock. This seems clumsy and doesn't make > use of the history feature of org clocking, which seems a waste! > > I have read Bernt's excellent document [1] but it doesn't help me for > this particular use. I've also searched the mailing list but to no > avail unfortunately. Does this help? Best regards, Seb --=20 S=C3=A9bastien Vauban