From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id 4FzTId5/UGDcMQAA0tVLHw (envelope-from ) for ; Tue, 16 Mar 2021 09:52:30 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0 with LMTPS id wNagHd5/UGBcFwAA1q6Kng (envelope-from ) for ; Tue, 16 Mar 2021 09:52:30 +0000 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 C36A415E37 for ; Tue, 16 Mar 2021 10:52:27 +0100 (CET) Received: from localhost ([::1]:59028 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lM6NG-0001Iz-2R for larch@yhetil.org; Tue, 16 Mar 2021 05:52:26 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:34342) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lM6Ml-0001Ic-1q for emacs-orgmode@gnu.org; Tue, 16 Mar 2021 05:51:55 -0400 Received: from out1-smtp.messagingengine.com ([66.111.4.25]:51407) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lM6Mj-0000U6-8c for emacs-orgmode@gnu.org; Tue, 16 Mar 2021 05:51:54 -0400 Received: from compute2.internal (compute2.nyi.internal [10.202.2.42]) by mailout.nyi.internal (Postfix) with ESMTP id 851EE5C01A7; Tue, 16 Mar 2021 05:51:52 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute2.internal (MEProxy); Tue, 16 Mar 2021 05:51:52 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fastmail.fm; h= references:from:to:cc:subject:date:in-reply-to:message-id :mime-version:content-type; s=fm2; bh=qmVbI3L5mhYj7AADLMxMm05WI+ aTqjH0WhnqhEhvMEc=; b=wdeuL7YLeRwSBzhIkL7XLMVbPpqarE2FeTIIB7KPEk E91pSMwgtVkdv0akpZiZgz2x7kdvShWaUPu/akY2xtUEM2hW+NXBK/81t6LQbu04 54DQo76pY80jJhbghid7d5n8kmVpVJUwCI6YTOcuqzNoeX7zTPTkL3yYHDBCiIJy pmIORgllnIW8O8WWvrPQhojqMQy2622Z7871uWbqWwJWvzP7p1gINCdWYnlZnhUL 2g08/s1hMuHgoLz02oX4oOxLICrWBC0pCdA/kl+csJAOBSbHGPVzzuVNdVXjADjR tk1xrhK4fhIogMFWx+ndXaMIAfgYN614zRqKG94yyvlQ== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-proxy :x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm2; bh=qmVbI3 L5mhYj7AADLMxMm05WI+aTqjH0WhnqhEhvMEc=; b=JvqaNxjGt+wkuMBmIED9ib MZmn0jkJdyhT05ATE5lcq0nK+CidNTnbIHPX3Ct9Gv5HCsQicf4pC1ed5prw7VAp lzcmN7q4AiuJSa9xy+EdpjjCdyRefHGhnXDCMU0KarFccd4KJHqWfxVWc8p3mlMV zOB+XyMtz29Gwh/8FJ9rzA5QY8z8fKuI0S3exsnj9V9sYrQH7y88v9Zpx+iZxHlK oFbnpZMJwrhDvFE9Vw5sX1MqBn3nZUrsZJoxoyBBvWd6+lVvI9EGl4jptKkNiL+A bJgejLhSTyYUcQjs2wVIEoT5Wr3U5U2fAdtosoIjOd2XUu8pTl+ad9ViSdWmBLSA == X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeduledrudefvddgtdejucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucenucfjughrpehffgfhvffuffgjkfggtgesthdtre dttdertdenucfhrhhomheplfhoohhsthcumfhrvghmvghrshcuoehjohhoshhtkhhrvghm vghrshesfhgrshhtmhgrihhlrdhfmheqnecuggftrfgrthhtvghrnhepvdeihfetueevke duteehudeihedvlefgieejhedvteefgeelleehhfejudeijeevnecukfhppeelhedrledu rdduleejrdehjeenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfh hrohhmpehjohhoshhtkhhrvghmvghrshesfhgrshhtmhgrihhlrdhfmh X-ME-Proxy: Received: from Lenovo.fastmail.com (ip5f5bc539.dynamic.kabel-deutschland.de [95.91.197.57]) by mail.messagingengine.com (Postfix) with ESMTPA id E67971080064; Tue, 16 Mar 2021 05:51:51 -0400 (EDT) References: <87eeggh0r5.fsf@fastmail.fm> <875z1rvniu.fsf@localhost> User-agent: mu4e 1.5.8; emacs 27.1.91 From: Joost Kremers To: Ihor Radchenko , No Wayman Subject: Re: org-capture: question about function to create template Date: Tue, 16 Mar 2021 10:36:34 +0100 In-reply-to: <875z1rvniu.fsf@localhost> Message-ID: <87o8fj8lze.fsf@fastmail.fm> MIME-Version: 1.0 Content-Type: text/plain Received-SPF: pass client-ip=66.111.4.25; envelope-from=joostkremers@fastmail.fm; helo=out1-smtp.messagingengine.com X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 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, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: emacs-orgmode@gnu.org Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: "Emacs-orgmode" X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1615888350; 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=qmVbI3L5mhYj7AADLMxMm05WI+aTqjH0WhnqhEhvMEc=; b=Td/8DQZXGsWAC+iIwLWPHVJxw2P8o+4Ah0S7PqKC4WQuUBLChgUo7giFW3RQsf2JS2Rhh4 MuUE3A1tC1aJQFtzqAjOLev3Omk7QfQxDu+YIlr9CSzacodBMO/zGOAEsoYHb88j1kGYR6 CAnQzVyUbooQcpxY+w5xIbqeYRoQzi/h5kRMGptlIR/68StXTKvttDP9G7OXexy28lw1vA 9iRo+y5fYRjVC1zelNsgAs16QnBtVSdr2BCDvqyQg5XUHsKSqX0jsrXkMdD28H/Jp0LkEa EW+RoFY45i2VTAIZLYXaQ4V/AzKl6IPnwDWKjRqJKQcXt7GXGFFPwmRV66gTeA== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1615888350; a=rsa-sha256; cv=none; b=m5OOSLNXFHZwUfgOiDFxv2sWj0Lypjmnk1XICjK8JhC4Dg0AK/v7epNQj/3lN8QFNbkL+x RXA4GSB+MUk1Sut6XGFS3bFt9XrO+wtj2yd+GWzxojTZlfpbK191L7zq6w2HJE0v/kElKw kCk39RReJGKpFdnPkCp9NosWEi/2aA6OaTDQ4c5kU2AzeBCmIzJcjSdm76tbq3KecYKJ3M kSTT6CHSnHCsC77n7PXvP31tgP9V+aTIgIXnJExHp2yFs6OvIBriKhQdBye4Jf5E7NHRCI 4Tqe2sQUz5MF1R6TxoTeOMuNRpjTcbP2RCHSi+TXpC4A83XOvW+0z9Hm09LK+A== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=fastmail.fm header.s=fm2 header.b=wdeuL7YL; dkim=pass header.d=messagingengine.com header.s=fm2 header.b=JvqaNxjG; dmarc=pass (policy=none) header.from=fastmail.fm; spf=pass (aspmx1.migadu.com: domain of emacs-orgmode-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=emacs-orgmode-bounces@gnu.org X-Migadu-Spam-Score: -3.10 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=fastmail.fm header.s=fm2 header.b=wdeuL7YL; dkim=pass header.d=messagingengine.com header.s=fm2 header.b=JvqaNxjG; dmarc=pass (policy=none) header.from=fastmail.fm; spf=pass (aspmx1.migadu.com: domain of emacs-orgmode-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=emacs-orgmode-bounces@gnu.org X-Migadu-Queue-Id: C36A415E37 X-Spam-Score: -3.10 X-Migadu-Scanner: scn0.migadu.com X-TUID: PxdKo/oikaRZ Hi Ihor & No Wayman, Thanks for your replies. On Tue, Mar 16 2021, Ihor Radchenko wrote: > Joost Kremers writes: > >> ... I was wondering if there's any >> way for this function to access the state of the ongoing capture process. >> Specifically, it would be useful for me if the function can find out the key of >> the template that the user selected. > > See org-capture-plist. Yes, I thought that might be it, but I wasn't sure. On Mon, Mar 15 2021, No Wayman wrote: >> From: Joost Kremers >> Specifically, it would be useful for me if the function can find out the key >> of the template that the user selected. > > This is stored on the above plist as :key. > > There are some corner cases to consider if you have overlapping > capture processes. > You'll want to look into `org-capture-get' and > `org-capture-current-plist' as well. Thanks for the pointers. I'll dive in a little and see what's best for my use case. -- Joost Kremers Life has its moments