From: No Wayman <email@example.com>
To: Nicolas Goaziou <firstname.lastname@example.org>
Cc: email@example.com, Ihor Radchenko <firstname.lastname@example.org>
Subject: Re: [RFC] DOCT: Declarative Org Capture Templates (easier template syntax)
Date: Wed, 23 Mar 2022 20:39:25 -0400 [thread overview]
Message-ID: <email@example.com> (raw)
Nicolas Goaziou <firstname.lastname@example.org> writes:
> The fact that we need a tool like "doct" to write templates in a
> form may be a sign that the data type is not good enough.
> Actually it
> sounds like a failure somehow.
Agreed. That's why I wrote doct in the first place.
As others have expressed, there's far too many elements required
to ask the user to recall what position they fall in.
A plist is better in that the keys describe their values and can
be specified in any order.
This also makes it easier for people to share templates, because
they can actually tell what the template is intended to do by
looking at it.
Another thing that is confusing about "capture templates" is that
the words "template" and "entry" are overloaded in the
documentation. From the docstring of org-capture-templates:
> Templates for the creation of new entries.
> Each entry is a list with the following items:
So org-capture-templates is a "list of entries which create new
entries via templates"?
Confusing for me now, let alone the first time I tried to write my
doct also does more to check the validity of the template's form
when it is defined.
I prioritized this because the worst time to figure out your
template is malformed is when you go to capture something in the
middle of another, unrelated task.
> Should templates definition be more compact out of the box?
> Could the
> data type be made more powerful to permit more complex templates
> relying on doct? IOW, can a tool such a doct be made transparent
> to the
My initial idea for integrating doct with Org was to just provide
a user option, e.g. org-capture-use-doct-syntax.
Then the only thing needed would be a conditional in
org-capture-upgrade-templates which would delegate to doct when
said user option is non-nil.
That would allow those who are interested in using the feature to
opt-in without breaking existing templates. Then as support for
older syntax is dropped, (if ever? it looks like
`org-capture-upgrade-templates' dates back to early 2017, and I
think it makes sense to retain such a path) those features could
be moved into org-capture.
I'm open to bringing doct's features into Org mode, but I'd prefer
it not to be spread out over another two years.
next prev parent reply other threads:[~2022-03-24 2:31 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-04-23 17:30 [RFC] DOCT: Declarative Org Capture Templates No Wayman
2020-04-24 10:01 ` Nicolas Goaziou
2020-04-24 18:01 ` No Wayman
2022-03-20 10:19 ` [RFC] DOCT: Declarative Org Capture Templates (easier template syntax) Ihor Radchenko
2022-03-20 13:17 ` Nicolas Goaziou
2022-03-21 9:14 ` Ihor Radchenko
2022-03-23 16:31 ` Nicolas Goaziou
2022-03-23 21:28 ` Tim Cross
2022-03-24 0:39 ` No Wayman [this message]
2022-03-26 8:30 ` Ihor Radchenko
2022-03-27 14:46 ` Ihor Radchenko
2022-03-29 14:19 ` Matt Price
2022-03-20 15:56 ` Mark Barton
2022-03-21 8:51 ` Ihor Radchenko
2022-03-23 14:32 ` João Pedro de Amorim Paula
2022-03-24 18:43 ` physiculus
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:
List information: https://www.orgmode.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
* 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
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).