From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp11.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id iJq7JhDYO2KOcwEAgWs5BA (envelope-from ) for ; Thu, 24 Mar 2022 03:31:44 +0100 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp11.migadu.com with LMTPS id aNn0IxDYO2ITxAAA9RJhRA (envelope-from ) for ; Thu, 24 Mar 2022 03:31:44 +0100 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 27EFBA34E for ; Thu, 24 Mar 2022 03:31:44 +0100 (CET) Received: from localhost ([::1]:39866 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nXDGI-0002aG-Fv for larch@yhetil.org; Wed, 23 Mar 2022 22:31:42 -0400 Received: from eggs.gnu.org ([209.51.188.92]:50472) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nXDF8-0002Zx-7G for emacs-orgmode@gnu.org; Wed, 23 Mar 2022 22:30:31 -0400 Received: from [2607:f8b0:4864:20::736] (port=33284 helo=mail-qk1-x736.google.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nXDF5-0003jr-NK for emacs-orgmode@gnu.org; Wed, 23 Mar 2022 22:30:29 -0400 Received: by mail-qk1-x736.google.com with SMTP id k125so2626290qkf.0 for ; Wed, 23 Mar 2022 19:30:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=references:user-agent:from:to:cc:subject:date:in-reply-to :message-id:mime-version; bh=YuS8uET3XFpeu9cGkf5kHUjrY5tKa1MDR2CmiGLZ5lk=; b=dCyHQn/OX0zBSFdrKRu+5GK+1lI7i+p5QQPL4X4xI2/AJMN9F3mkCjgXXwRN28+AF4 +4UFhq+P1fjfGcdBlXvAkimJtx14QSqWZ6NkfBLZMth8o8IHb9C4sKf1fYyCzp1GdJ7W p/XFoCweyOTTK858aqDt5Hd4lOpXlr7gh+pkV7NJiUNb5Xtr3JmMo/rA5/W+q09YcSsp CvAly8J98zQXgEPfd98N90zPkYa73qXVbJTWQxpTgJ9UXACLmmQ3molirIMOWy8b7HFJ nMTb1MrwT5nYt6M66P1jNb16Ouubz2GcHO6hP7cwexc1MaEz3Ah4JgntxEjMVRAC2ZaM ItIA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:references:user-agent:from:to:cc:subject:date :in-reply-to:message-id:mime-version; bh=YuS8uET3XFpeu9cGkf5kHUjrY5tKa1MDR2CmiGLZ5lk=; b=JoQBEtrcxTE0ExX3o5CuW2moH97IUEuvpOe/srjQt31fFsOYb58ewl+TZb7v9nViBi HuF61LVAjau5M3WDocqjVsotfLIOrt5UInSSvwfAh2sLVZuo0+fbdMsABbsYq+piD/jL VOSN2qma1JhR7q4AbER+kK3kcat1BnLtN08ayRoQBIfJNTIFd3afwqcO0HxFwYbtIApP TzjsNz3pRv75CY3LRLhNO5IXfjvyWvzzUCTG3JKsVfo+2KAdAa/2O+Ugb40wdUo+lDlT btKxh8Kb1WkK1nYrjnpUm6Lxtuf367sqCMNST3eaVOiKH0nL6pzhxcbDxCh7tUFIIct9 DQQg== X-Gm-Message-State: AOAM531o6rilZ3fT/NWQdUmGvZo3TnOgjvTwsgtXHEYwwqCCJpEIQaQd py3nUpwtY24PPcr53fe+1gNmSTn1FKM= X-Google-Smtp-Source: ABdhPJxx4pVgz4Imf4OfX+o4lBNwD7PDyj8V3bnOog83dJ3x/4YUpND9vlXB0aiWJkii4iiAedBOxg== X-Received: by 2002:a37:5d2:0:b0:67b:136a:3b1e with SMTP id 201-20020a3705d2000000b0067b136a3b1emr1940821qkf.169.1648089024976; Wed, 23 Mar 2022 19:30:24 -0700 (PDT) Received: from arch ([2601:82:c200:166d:afae:ebe6:a0e2:409e]) by smtp.gmail.com with ESMTPSA id w3-20020a05622a190300b002e1f084d84bsm1553032qtc.50.2022.03.23.19.30.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 23 Mar 2022 19:30:24 -0700 (PDT) References: <87wo66t8i7.fsf@gmail.com> <87y2qlgq33.fsf@nicolasgoaziou.fr> <87d07wkbkz.fsf@gmail.com> <87czihdiyy.fsf@localhost> <875yo8u5kj.fsf@nicolasgoaziou.fr> <87bkxzd5wc.fsf@localhost> <87wngkk4vc.fsf@nicolasgoaziou.fr> User-agent: mu4e 1.7.10; emacs 29.0.50 From: No Wayman To: Nicolas Goaziou Subject: Re: [RFC] DOCT: Declarative Org Capture Templates (easier template syntax) Date: Wed, 23 Mar 2022 20:39:25 -0400 In-reply-to: <87wngkk4vc.fsf@nicolasgoaziou.fr> Message-ID: <87sfr8gk00.fsf@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; format=flowed X-Host-Lookup-Failed: Reverse DNS lookup failed for 2607:f8b0:4864:20::736 (failed) Received-SPF: pass client-ip=2607:f8b0:4864:20::736; envelope-from=iarchivedmywholelife@gmail.com; helo=mail-qk1-x736.google.com X-Spam_score_int: -6 X-Spam_score: -0.7 X-Spam_bar: / X-Spam_report: (-0.7 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, PDS_HP_HELO_NORDNS=0.659, RCVD_IN_DNSWL_NONE=-0.0001, RDNS_NONE=0.793, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=no autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: emacs-orgmode@gnu.org, Ihor Radchenko Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: "Emacs-orgmode" X-Migadu-Flow: FLOW_IN X-Migadu-To: larch@yhetil.org X-Migadu-Country: US ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1648089104; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=YuS8uET3XFpeu9cGkf5kHUjrY5tKa1MDR2CmiGLZ5lk=; b=NsjZYO7ewLcMmVvrvznDadeQYp6yjFm7MbXlO/PB6hxmqmhVjn+ZFY9ErVcmSiqWBa8Dui jqokEergCaNkoMis/HbEKkxgJ4N3mA/mfjATr5Hvc0dndvsfGyt1xQrc36C5vcGiJ4W1oS KMmTZ1BY52cNeXejazBFMtx03T5luBn9xfhF2h6sxnEFpXqAEN3YmM0v5jXTOKCK7gwM6L fcEhakgjc2wq5JSLRksvmjXf/6DVK88vMxWebdAXjyfGMU/ZsXIhE+xWcnABsIMFcpV7rR BpBqMWN8fLkKjXflLvLKaYRib3ZHGnbMuBY4vjuRL+A3KsRDsSNS24dGRp10Pg== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1648089104; a=rsa-sha256; cv=none; b=BVsJo4J58NvWjqjrPc5kqlCh+/mzxfTfpH6bOVGLmJZayEvDzuajhH9cdwcZFWGvi2H0fM us9u5xn2SO3eaXIANxQ8I8KVWovph3CZhgrGNpsQsxWWW998uJfJCxUgmID5WcPTRn5jwD PkDioh+Xici8qEXnpMZ4DjzgjzSZRL/3MyRA88rnoefTUm1w+ZMy8vFA9Zu2te+Q7dJpee fBxG3dgFR1gZijbhvHlRugqA1oiTpiZBrO/vgnLzJQLPc00xbE7ejxsCwM+6ipnIvKSnWR PyyRhmUjoZYJtYL3xj6zr2MOkLigIBxxoLwUn9swgvedVmgt0BTx4yOLeuBsDA== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20210112 header.b="dCyHQn/O"; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none); spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org" X-Migadu-Spam-Score: 6.11 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20210112 header.b="dCyHQn/O"; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none); spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org" X-Migadu-Queue-Id: 27EFBA34E X-Spam-Score: 6.11 X-Migadu-Scanner: scn1.migadu.com X-TUID: iKUHWqUpTIHx Nicolas Goaziou writes: > The fact that we need a tool like "doct" to write templates in a > compact > 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 own templates. 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 > without > relying on doct? IOW, can a tool such a doct be made transparent > to the > user? 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.