From: Carsten Dominik <carsten.dominik@gmail.com>
To: Philip Rooke <phil@yax.org.uk>
Cc: emacs-orgmode@gnu.org
Subject: Re: Bug: datetree capture from agenda [7.5 (release_7.5.135.g7021f.dirty)]
Date: Thu, 7 Apr 2011 17:05:03 +0200 [thread overview]
Message-ID: <CA8199AB-7C1E-44A5-89D8-E1AB871FC750@gmail.com> (raw)
In-Reply-To: <m2aag3ai76.fsf@bo.sak.lan>
On 6.4.2011, at 12:50, Philip Rooke wrote:
> Carsten Dominik <carsten.dominik@gmail.com> writes:
>
> Thanks Carsten,
>
>> I can see that it might be nice to simply add some text
>> under the date headline in a date tree, in order to build
>> up a long journal entry from little snippets.
>
> Yes, this is exactly what I do over the course of the day and I find it
> very useful. The trouble I run into is that, all too often, I forget or
> don't have time to add an entry on the day the noteworthy event
> happened. I use the agenda capture action (k c) in this situation since
> the date I am on in the agenda is picked up automatically by the
> template and the right date headline is created at the right place in
> the journal. Currently I have to then cut/paste the note, which is the
> bit I was trying to avoid.
>
>> However, you are trying to *mix* headline entries and plain entries
>> under the same date node in the tree, and this seems to be impossible.
>
> Sorry, my fault, the full version of journal template I currently use
> ends up creating entries like:
>
> *** 2011-04-06 Wednesday
>
> Try and clarify journal/note taking use case for Carsten
> [2011-04-06 Wed 10:03]
>
> Apologise for confusing Carsten as I don't actually use headline
> entries in the journal, plain only
> [2011-04-06 Wed 10:05]
This has kept me thinking. I think it should be possible
to add plain text templates to a node target, and now I think I
know how to do this in a way that allows mixing with headlined
templates. I am just adding plain text stuff to the text before
the first the first child, and entry-types as a child *after* this
initial text, however long it may be.
There are still good reasons so use the setup we have
constructed the other day, i.e. using only headlined snippets
for the journal. One reason to use this is that you then
have structure editing at your disposal to reorganize
the journal. For example if you have added something to
a past date, then you can go in and easily move that new
entry to the "right" position in the journal node, so
that the sequence of events during that day is
reflected correctly.
However, is you want, you can now use plain templates and point
them at a date tree or any other Org node, and get what you expect.
Here is an example:
(setq org-capture-templates
'(("h" "Journal headline" entry (file+datetree "/tmp/journal.org"))
("n" "Journal note" plain (file+datetree "/tmp/journal.org")
"%<%H:%M> %?" :empty-lines 1)))
Thanks for finding this inconsistency, Philip.
- Carsten
>
>> Wouldn't a better strategy be to have the "plain" section be started with a time,
>
> Well, as you see above I actually do like to have the time of the entry,
> but the only way I thought I could do that was using the %U keyword in
> the template (which is clumsy as it then duplicates the date/day).
>
>>
>> (the %<%H:%M> requires the current git release...)
>
> ... which, coincidently, seems to have appeared this morning :-)
>
> That means I can use something like:
>
> (setq org-capture-templates
> '(("e" "Journal entry" entry (file+datetree "/tmp/journal.org")
> "* %<%H:%M>\n %?")
> ("l" "Journal late entry" entry (file+datetree "/tmp/journal.org")
> "* Retrospectively added %<%Y-%m-%d %H:%M>\n %?")))
>
> Used from an agenda action the retrospective date headline/notes are
> created and filed in the right place, giving something like:
>
> * 2011
> ** 2011-04 April
> *** 2011-04-05 Tuesday
> **** Retrospectively added 2011-04-06 11:35
> Checked with Bastien about committing doc string changes
> *** 2011-04-06 Wednesday
> **** 11:33
> Updated Org to latest version in order to get new capture keyword
> expansion capability
> **** 11:36
> Problem solved. Brilliant, that works. Carsten never ceases to
> amaze...
>
> Thank you.
>
> Phil
>
prev parent reply other threads:[~2011-04-07 15:05 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-04-05 21:50 Bug: datetree capture from agenda [7.5 (release_7.5.135.g7021f.dirty)] Philip Rooke
2011-04-06 6:52 ` Carsten Dominik
2011-04-06 10:50 ` Philip Rooke
2011-04-06 11:06 ` Carsten Dominik
2011-04-06 11:09 ` Carsten Dominik
2011-04-07 15:05 ` Carsten Dominik [this message]
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
List information: https://www.orgmode.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CA8199AB-7C1E-44A5-89D8-E1AB871FC750@gmail.com \
--to=carsten.dominik@gmail.com \
--cc=emacs-orgmode@gnu.org \
--cc=phil@yax.org.uk \
/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 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).