emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* Override :clock-in (hence org-clock-in) behavior for a specific capture template
@ 2018-07-14  4:59 Cody Goodman
  2018-07-14  6:16 ` Nicolas Goaziou
  0 siblings, 1 reply; 2+ messages in thread
From: Cody Goodman @ 2018-07-14  4:59 UTC (permalink / raw)
  To: emacs-orgmode

[-- Attachment #1: Type: text/plain, Size: 1349 bytes --]

Here is my detailed problem exposition exported from org:

1 executive summary
===================

  I want to start at a child node and clock into the grandparent rather than
  the current child at point in a capture task


2 my capture
============

  ,----
  | ("f" "video game" entry (file+olp+datetree
"~/org/videoGameImprovement.org")
  |  "* %<%Y-%m-%d %H:%M>\n** game notes
  | *** %?
  | ** video(s)
  | *** video 1
  | **** note 1 for video 1
  | " :clock-in t)
  `----


3 what happens
==============

  I'm clocked into the place where `%?' takes me in the capture template


4 what I want to happen
=======================

  I want to land at the first child of the `game notes' node but clock
  into the `%<%Y-%m-%d %H:%M>' node 2 levels up


5 what I don't know how to do
=============================

5.1 In the capture template, I don't know how I could selectively use my
own implementation of `org-clock-in'
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

5.1.1 Maybe I could have some sort of local binding surrounding just that
capture which would be used?
------------------------------------------------------------------------------------------------------

* 5.1.1.1 advice?


* 5.1.1.2 is an `add-hook' possible only within a certain scope?


Thanks,

Cody

[-- Attachment #2: Type: text/html, Size: 1710 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: Override :clock-in (hence org-clock-in) behavior for a specific capture template
  2018-07-14  4:59 Override :clock-in (hence org-clock-in) behavior for a specific capture template Cody Goodman
@ 2018-07-14  6:16 ` Nicolas Goaziou
  0 siblings, 0 replies; 2+ messages in thread
From: Nicolas Goaziou @ 2018-07-14  6:16 UTC (permalink / raw)
  To: Cody Goodman; +Cc: emacs-orgmode

Hello,

Cody Goodman <codygman.consulting@gmail.com> writes:

> 4 what I want to happen
> =======================
>
>   I want to land at the first child of the `game notes' node but clock
>   into the `%<%Y-%m-%d %H:%M>' node 2 levels up
>
>
> 5 what I don't know how to do
> =============================
>
> 5.1 In the capture template, I don't know how I could selectively use my
> own implementation of `org-clock-in'

You can execute arbitrary Elisp code in a capture template:

%(sexp)

You can use it for side effects, i.e., clocking in the appropriate
place.

Regards,

-- 
Nicolas Goaziou

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2018-07-14  6:16 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-07-14  4:59 Override :clock-in (hence org-clock-in) behavior for a specific capture template Cody Goodman
2018-07-14  6:16 ` Nicolas Goaziou

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).