From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1.migadu.com ([2001:41d0:403:4876::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms1.migadu.com with LMTPS id AE8BD3hkLmaVMAAA62LTzQ:P1 (envelope-from ) for ; Sun, 28 Apr 2024 17:00:08 +0200 Received: from aspmx1.migadu.com ([2001:41d0:403:4876::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1.migadu.com with LMTPS id AE8BD3hkLmaVMAAA62LTzQ (envelope-from ) for ; Sun, 28 Apr 2024 17:00:08 +0200 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20230601 header.b=aSf0FxLb; 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"; dmarc=pass (policy=none) header.from=gmail.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1714316408; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=d4fX6YAWmPlm27NRihBGNuKDLJkAhKTQBcRygzAdQDU=; b=TAf+fTySwF6O0FdC0vWnYuBT8fBbTZQzDwZnIO+CRJj89ku1foXX1FAq+pzRI0TaIGgjE7 q7zjrJR+SdBi/AFFUnl8Gkd+jfyL+IYb2ntJ4deu1DU+mii+Wsq+lVJ3AkCBuaexFwuilh EOCfLYIaqQa7Wf3WupZ4jux8YM5M7RFRUrzQZbNmjGWnoRcl//E7jrMJOy4NdQb6mg9U2n mhy6JjrVc5WKWY2mSVsGtIJS686o517s14ioNze9pI3cGwPFAKBfTNqMQgg5UQwhk6jMks 0ASyNHXcBm6ap2resQ4CQsPftYxGb9Y3hcmO7Thdn6SF7jWdP6XVYEQsbifA0g== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20230601 header.b=aSf0FxLb; 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"; dmarc=pass (policy=none) header.from=gmail.com ARC-Seal: i=1; s=key1; d=yhetil.org; t=1714316408; a=rsa-sha256; cv=none; b=eOdyBGCzRESsb7YrcdphZ0uzG74bzef/8hxU5YlsFi+MMGIkaD6RYugktLBR4yd6M1yF1B 8I6drdG38BbD7wRYPlWb/MrxX2cZFthzynnDT98+JKQSPVvARjf9OCCy7lJqwUmFTZZO0W MBAywDc0/AFbJiSD89XMzpCXRDKW+l5/0i3EpC1umkakVgED+Ib5gjzXuEtbGrYXQTHxm+ WvWcsM/zu51gzFc4Zxf7mZAgq4DmnXbSJSulof2Qsw0WKnf5cpgk2uEIBN6Oex980T3Top s+mcy3dAkm4IduoJgQiVEIiggmnKoJoiiYSWkJTSLl3x7SJ2fYQykpIdow+6uw== 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 19C5D74B0C for ; Sun, 28 Apr 2024 17:00:08 +0200 (CEST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1s15zh-0006G3-78; Sun, 28 Apr 2024 10:59:09 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1s15zf-0006Fk-UI for emacs-orgmode@gnu.org; Sun, 28 Apr 2024 10:59:07 -0400 Received: from mail-ej1-x62c.google.com ([2a00:1450:4864:20::62c]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1s15ze-0004Mk-Bj for emacs-orgmode@gnu.org; Sun, 28 Apr 2024 10:59:07 -0400 Received: by mail-ej1-x62c.google.com with SMTP id a640c23a62f3a-a58e787130fso170687966b.0 for ; Sun, 28 Apr 2024 07:59:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1714316344; x=1714921144; darn=gnu.org; h=to:subject:message-id:date:from:mime-version:from:to:cc:subject :date:message-id:reply-to; bh=d4fX6YAWmPlm27NRihBGNuKDLJkAhKTQBcRygzAdQDU=; b=aSf0FxLbFIhXmu3eHxDYQXq5D6Ubohh+lTklizSUw+k1DZJrH40mLCLHqovLNQchp/ M68L4QITFGJqyBWRFwVvMssbtsqZUqXrXLUUlU8OkeurqX0/SkMW1VtzTCwIt1iGP9oL oZqQBe+11TIYzlap43+atzN6bZDHjrPCIEchOyYn58zX+CJ6Z2QZTY5Ej7Re6CDOk54T 411+ajtbEM9SOSefzibWxCaL83LsRiOwWz0BbLNfkbth7DXX6uZ3Dv20kFggsR8h6yA2 NB+4MOK0mWYmhYAQjHduw1xSyvRpD7oi+rIf1TQIaVsaBG9guqeYQQJqCgbn79WrrVE2 H7iw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1714316344; x=1714921144; h=to:subject:message-id:date:from:mime-version:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=d4fX6YAWmPlm27NRihBGNuKDLJkAhKTQBcRygzAdQDU=; b=RcorotyraO05shzlXVgi57NCUnZdZ0BG36LXMWtTAcbuOKdseip8h7YtkevgVxXBx3 SsEc/jyHebhnHkelJ+FMRHuw6p/sntxnZGCyhLcZtRvKsmUguVyQrnF5Fh4ltZGdRzma tjwrVd5VL8dU3viVIKTWjDw7ooGgbkGE1IGPr7niKMSDaXBmXrjwualCTI1dcCyszXX1 fUv204VnkQ+IWoLk3Rovv9XpsegWEzKlN8kJnGfxJM3vtijhLDHtv30PFrmE1JzfBGhI 2i4REBK3PPi8oYGo8NlS6vX+Y78LuwgmHdWanDNe+gRCpifOYXXqBQ0OjLUKr6n4uKvz ehiA== X-Gm-Message-State: AOJu0YyMyxsMNONjjNy+FGgCEkIilklvs5oxYsXyQ1x8PLhrUsCCyPB6 KWfXz/C9ETi3C46bkOdRDfW2fScCaAfKsI/EKNpRcNTVXc2YoBoLpvmp1rJ1heOG6i+ka1YKCdN fjNOq2RI+6k7oI79mrqtei39PLg66Ig== X-Google-Smtp-Source: AGHT+IHxLORmwzoXGY59KIkgGH8FsxJtxVGJct1vB12NFUNHw7m/ir8vHSkKZIrVXJGNImVVpleWWJxZTgZKzhv/s/Y= X-Received: by 2002:a17:906:f743:b0:a58:f13d:d370 with SMTP id jp3-20020a170906f74300b00a58f13dd370mr2126786ejb.5.1714316343889; Sun, 28 Apr 2024 07:59:03 -0700 (PDT) MIME-Version: 1.0 From: Nafiz Islam Date: Sun, 28 Apr 2024 10:58:53 -0400 Message-ID: Subject: [FR] Support headline as a function for file+headline target for org-capture-templates To: emacs-orgmode@gnu.org Content-Type: multipart/alternative; boundary="000000000000b5d78a0617296079" Received-SPF: pass client-ip=2a00:1450:4864:20::62c; envelope-from=nafiz.islam1001@gmail.com; helo=mail-ej1-x62c.google.com X-Spam_score_int: -17 X-Spam_score: -1.8 X-Spam_bar: - X-Spam_report: (-1.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_ENVFROM_END_DIGIT=0.25, FREEMAIL_FROM=0.001, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=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.29 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: emacs-orgmode-bounces+larch=yhetil.org@gnu.org X-Migadu-Country: US X-Migadu-Flow: FLOW_IN X-Spam-Score: -6.70 X-Migadu-Queue-Id: 19C5D74B0C X-Migadu-Scanner: mx10.migadu.com X-Migadu-Spam-Score: -6.70 X-TUID: kGhXTVB5DFMV --000000000000b5d78a0617296079 Content-Type: text/plain; charset="UTF-8" Right now, only the file name supports being either a string, symbol or function, etc. Nonetheless, it would be nice if headline could be a function that takes in as parameter a list of all headlines present in the file so that we can dynamically pick a headline under which we want to add an entry. The function can also return a string to represent a (potentially) new headline to insert. My use case for that is I have an org file in which each headline is a specific time, and I want to reuse a headline that is only within 5 minutes behind the current time. --000000000000b5d78a0617296079 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Right now, only the file name supports being either a= string, symbol or function, etc. Nonetheless, it would be nice if headline= could be a function that takes in as parameter a list of all headlines pre= sent in the file so that we can dynamically pick a headline under which we = want to add an entry.=C2=A0 The function can also return a string to repres= ent a (potentially) new headline to insert.

My use= case for that is I have an org file in which each headline is a specific t= ime, and I want to reuse a headline that is only within 5 minutes behind th= e current time.

--000000000000b5d78a0617296079--