From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp10.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id aPoQFO2ldmI4agEAbAwnHQ (envelope-from ) for ; Sat, 07 May 2022 19:01:33 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp10.migadu.com with LMTPS id MLAWE+2ldmI1wAAAG6o9tA (envelope-from ) for ; Sat, 07 May 2022 19:01:33 +0200 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 A9EBA353E7 for ; Sat, 7 May 2022 19:01:32 +0200 (CEST) Received: from localhost ([::1]:44948 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nnNoB-0003eI-R3 for larch@yhetil.org; Sat, 07 May 2022 13:01:31 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:43634) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nnNnH-0003bm-1F for emacs-orgmode@gnu.org; Sat, 07 May 2022 13:00:35 -0400 Received: from mail-am6eur05olkn2081e.outbound.protection.outlook.com ([2a01:111:f400:7e1b::81e]:47360 helo=EUR05-AM6-obe.outbound.protection.outlook.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nnNnE-0001jj-Md for emacs-orgmode@gnu.org; Sat, 07 May 2022 13:00:34 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Ld2UaSLRb3ymVVamLfXX93ulotw7MAWMD+Gccw5/olZAf6NH+SNv6IJtc1WCm4UtxxMxIP6jbQWfPhZHVtewfm0JAPnJcmLUKv+rJ1dpwhAKrFTRiRIl1/KAmB3DwVZePJlYP5OhXpdlRGUm/si1phUYfGUQi9onqZVAq44CdSXpaq0s8XpaMpfCHtUS0+y/xlxSTPaNuez43KrPYZtLuG6FYmm3kwbS7f9tI4LxGo3BxAqdI/DEmkEeQH76aGoNwcaItm0mTk4ot7pX47+Im9E1PSc/qtW4pkQSxdHe30miuwBPR5SrwH/fVJeAIAfhOlaeo9QPZJE17a/1C78CcQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=gRZ+PbiNnaJoVPtI0SqZloc1vpib+zqexJVxtgGJ7OQ=; b=J2vDYN6EFAmxUD6PDqSUAaNRVaJaoXHL+Chkb/TZFunLgp82GEDnKpGmOTJZdKlK+eV4Mf8aQfmdBNrxI29WvD5q6l1gvWiej9azw+2yqKBBM6EVINVx2ZhTtKgRn5wkgyKUie9fLqTcXDJyZuifP1diLOQLBl/cE+wRr3E7a2ygx6/Oav7R2YnaxvCv8r2Pqb8X6UpTFC/vfDk57uBbNiHaAUtaXETpYAw5PU9aVsYUMDXvNKgm7W/OsRxBKlGqyaaDk/b3nWHs0boI5wVOlwgWsd4aE+cmGBc3zsOiIUtMnvV2Osyajisq+UieXmtNJI9wLSpHrvrws10l/4++0g== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=hotmail.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=gRZ+PbiNnaJoVPtI0SqZloc1vpib+zqexJVxtgGJ7OQ=; b=iF4hzWKFO6SqG47YBaDX0LLhhHqXSFstIWT9QlrGEKQPodoGOhrVLSbzu6S5/w+rDnHU7AxNf4rnx/jA7UeTD5PcKf3LBhRFqmc01nPAoUM5Nau83swaVuQRz2WMLQVIQB/qO25Ozrf4VqUAfoBeVRws3rkJ8+DKq3bQJHiyES24fy9lJgcOlma2KUxFjjsZFbtVjG0EUJgW2lztJ73cd9JyZI2IbMF6+StWq4hJW4Ka2+3MAUHZqv6lthh2u4kMF41tyzKG/pHSZ3bRoUPEgIJtcc2zi9oOldZvaaJR/ojHKv8Bhv5IpXJSpoVkLGU730cQ2yzIjYM9MYgrU45Fpg== Received: from DB9PR06MB7753.eurprd06.prod.outlook.com (2603:10a6:10:258::12) by HE1PR0601MB2300.eurprd06.prod.outlook.com (2603:10a6:3:90::14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5206.27; Sat, 7 May 2022 16:55:27 +0000 Received: from DB9PR06MB7753.eurprd06.prod.outlook.com ([fe80::4494:a012:c03b:68d]) by DB9PR06MB7753.eurprd06.prod.outlook.com ([fe80::4494:a012:c03b:68d%4]) with mapi id 15.20.5227.021; Sat, 7 May 2022 16:55:26 +0000 References: <87fsln6iho.fsf@localhost> <87v8uhyksw.fsf@localhost> User-agent: mu4e 1.6.10; emacs 27.2 From: Ignacio Casso To: Ihor Radchenko Cc: emacs-orgmode@gnu.org Subject: Re: [BUG] org-complex-heading-regexp should consider COMMENT keywords [9.5.2 (release_9.5.2-25-gaf6f12 @ /home/ignacio/repos/emacs/lisp/org/)] Date: Sat, 07 May 2022 18:54:38 +0200 In-reply-to: <87v8uhyksw.fsf@localhost> Message-ID: Content-Type: multipart/mixed; boundary="=-=-=" X-TMN: [7OcpM1wvocu+qkhQZ4wtfFaanQXlPT0Y] X-ClientProxiedBy: PR0P264CA0221.FRAP264.PROD.OUTLOOK.COM (2603:10a6:100:1e::17) To DB9PR06MB7753.eurprd06.prod.outlook.com (2603:10a6:10:258::12) X-Microsoft-Original-Message-ID: <87v8uh705j.fsf@hotmail.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 76065827-b304-4651-37a7-08da304a61ec X-MS-TrafficTypeDiagnostic: HE1PR0601MB2300:EE_ X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: QGtPfOrfohCdVgvtU/0VD8jCWPtcCfByZff0JdoO2fW4+ncQAIGT9iudJeV2uBxB8E1q+fblktnqMesgc0DHagyX4JeWdCayF5wBiJ/iQEw/CMacpLaZ/xfkP+Ue+/v3GPGqy+QF2dnjTTZhdILJUD4IMHRRc2OKIyRvVwvK3CVgU+Dn/9odRdc1YGhldJh8rrPq+Lnc4QXTTNl5xHNv1ndq7vFLraK7SKBun1pqiWPLXgYo/eXWD7GIRL8hb2KniD6L2GKtOLx49WP+eAQeT8VPesoOwz/FdRhAtjmaTShjNLTalLrJ4ghKkwQ3SDRU/Yezodvoxo2f7EAJkSR0Q+9onpW7VpC1LtQTrhVCRuUDMMLulIbLt0A5/TetIYYLkcEc3Io0K+HIAAZvL+PCRyqGmV8XWq2BXq0YtK7CF5g3kZ3ejSihDf+zjUX545ODcGKGk38XF5T5aYUljuVgzQj5c6UIzODdZIWgCSc+RQ1KfX7g26+iTcciKBNtupUizQAb5KnBMyPqz1YdNxChclAmNWWzRmQkaV98SbyE0203mmBdThOiJionWs+5SRehGtlGAsg/Uumg+FSC1+xA2myMiAi0igwZLrzNqN4gc9FJBop734FQ+g1ms4D4Iyhqg9heHAoHR8cnbBg89zdWFUJKPr+grCEgoZDa8C+7a2VsQZeuycoEPeh6ipcS/n1kp+wC5sh1m84SsJtZ09UClw== X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?us-ascii?Q?9uIJGbgBmMkMBy8WVseb/HKGKFgJfliUbWO0S3xv+GuFes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Zs9AWlhnbPMKA8VKE7nJD2WPwUv18L4gEHKCmMtwpkN6kltZ7baY?= =?us-ascii?Q?2Yowd1uAuhtIZm6Am/j0It/S7R1mm6fBDQ55z/CJNEttWNWJtY7xDcFF0S/M?= =?us-ascii?Q?kovvD09dBGhcrYFXIVrRv3RtizEosR4woRQOMbSaWeznODwSg4I8kSLO0zUc?= =?us-ascii?Q?JiRUrwDmL4siJK+DLaR3VuUnPtjzxDBescIAMhAQAsfdEcLTV6yM4sWxNEXZ?= =?us-ascii?Q?wS/4pLxFChpnb0ZuE4IWzYPFqqjo0YLi+vPfzlsarwILZKkDM7Lk3WJKTJ8x?= =?us-ascii?Q?H+X+oEaBimb+Vu3zLfMDtLqujUEr1qkKKEJBG05Sjen8zc6V+lEQM127dakY?= =?us-ascii?Q?I9dzYGgcqnzGo054PQQ2jFCUgj/i3YQwEvKb8OKP73j1FsSsH7oFeT747It0?= =?us-ascii?Q?7G3QaxkIFZsmz4to93NH8dqla4btpzrdMJ5rIoxmIRQcisXJggmWN6gG0RwD?= =?us-ascii?Q?GjuJ2nEDmCE7uuj8xS0Qor9PVSYgSJWPDGSJeaBo138JuRXfwW+cIWTLO1NO?= =?us-ascii?Q?f4l2XYuAA0w=3D?= X-OriginatorOrg: sct-15-20-4755-11-msonline-outlook-6e454.templateTenant X-MS-Exchange-CrossTenant-Network-Message-Id: 76065827-b304-4651-37a7-08da304a61ec X-MS-Exchange-CrossTenant-AuthSource: DB9PR06MB7753.eurprd06.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 07 May 2022 16:55:26.9161 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: HE1PR0601MB2300 Received-SPF: pass client-ip=2a01:111:f400:7e1b::81e; envelope-from=ignaciocasso@hotmail.com; helo=EUR05-AM6-obe.outbound.protection.outlook.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 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, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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" X-Migadu-Flow: FLOW_IN X-Migadu-To: larch@yhetil.org X-Migadu-Country: US ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1651942892; 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=gRZ+PbiNnaJoVPtI0SqZloc1vpib+zqexJVxtgGJ7OQ=; b=AZdUMYxUo7PNcLMDs60wwGdkLyLQbT1oqcjpKY3OJA81i55AveEvbJJa7dKUBg/vA7AUij X/XtQhssf2c2PHmMKXCAR/OJtDtnGlc6qhfuGophcAK8+anaJOZNAt+hb32ngKX94KhuAa 1jzOK3YASc3CUntKrTfmsrNnXx/0mkWzNR0vEeMWXlWjyzaB+Lj10c+akg5ACtPBDjfHWM 6DUoRFrS183ZachriQdIt4hm8IDOol1OYeVl2k2ZWc85vWYDz9lPTt+cJKyRpLt0M48qGs iMB2tbK/jbrBoa0/n+uxIO6lvBn+sJN+H+PeZxhC9B5GnaJd2iuzmkeehLMjKw== ARC-Seal: i=2; s=key1; d=yhetil.org; t=1651942892; a=rsa-sha256; cv=pass; b=Wx1rIaNu41IT6j4NCMbgEeEZtu15IJzMHLsSlGOJN6OVaSzWljZvbno4IMVIiXMT453MKz lGmOyHkm7pSM/B/ejClprN5SihmCipv4lQGzLeyNYU0p0fAIAArZBEKGR0AKJ57QEIG8A8 LPFqGOrIfXinD2GEWxoxFf6u8eWDkRkArtWzAb8V6LUOKnH9y8cbudDxJlMxGKcoDj0fSe o64zP7mzhDUoD3ZFb5qHg85VRSGCbyHbGNAToDp5n1mhRD2ITietP3PCTaRG+yxrfT/t7i 8RfbJt1j7HsqXIgrntftYSUb6uHt6cNDbpVGOOJgosYLFEpkzRHKY3Ke0tiBqg== ARC-Authentication-Results: i=2; aspmx1.migadu.com; dkim=pass header.d=hotmail.com header.s=selector1 header.b=iF4hzWKF; arc=pass ("microsoft.com:s=arcselector9901:i=1"); dmarc=pass (policy=none) header.from=hotmail.com; 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: -4.80 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=hotmail.com header.s=selector1 header.b=iF4hzWKF; arc=pass ("microsoft.com:s=arcselector9901:i=1"); dmarc=pass (policy=none) header.from=hotmail.com; 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: A9EBA353E7 X-Spam-Score: -4.80 X-Migadu-Scanner: scn0.migadu.com X-TUID: LTeg2QqpFpz2 --=-=-= Content-Type: text/plain Ihor Radchenko writes: > Ignacio Casso writes: > >>> Sounds reasonable. Could you prepare a patch? >>> COMMENT should be inside a shy group and note that there might be an >>> arbitrary number of space after COMMENT string. >> >> Here it is. > > Thanks! Could you also update the org-complex-heading-regexp-format > docstring and make the commit massage conform with > https://orgmode.org/worg/org-contribute.html#commit-messages (also see > https://orgmode.org/list/87ilqz14ys.fsf@localhost)? > > Best, > Ihor Done. I attach the patch: --=-=-= Content-Type: text/x-diff Content-Disposition: inline; filename=0001-lisp-org.el-match-COMMENT-in-org-complex-heading-reg.patch Content-Description: Patch >From 646f2a792dc5c6e6fa3933eb1d06420c86cd53c3 Mon Sep 17 00:00:00 2001 From: Ignacio Date: Fri, 6 May 2022 13:51:14 +0200 Subject: [PATCH] lisp/org.el: match COMMENT in `org-complex-heading-regexp-format' * lisp/org.el (org-set-regexps-and-options): Change `org-complex-heading-regexp-format' initialization so that the regexp it produces also matches a headline if it is commented. --- lisp/org.el | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lisp/org.el b/lisp/org.el index 1d5fc3903..cab59b87c 100644 --- a/lisp/org.el +++ b/lisp/org.el @@ -3846,7 +3846,8 @@ expected to be bound to nil when matching against this regexp.") "Printf format to make regexp to match an exact headline. This regexp will match the headline of any node which has the exact headline text that is put into the format, but may have any -TODO state, priority and tags.") +TODO state, priority, tags, statistics cookies (at the beginning +or end of the headline title), or COMMENT keyword.") (defvar-local org-todo-line-tags-regexp nil "Matches a headline and puts TODO state into group 2 if present. @@ -4213,6 +4214,8 @@ related expressions." "\\(?: +" org-todo-regexp "\\)?" "\\(?: +\\(\\[#.\\]\\)\\)?" "\\(?: +" + ;; Headline might be commented + "\\(?:" org-comment-string " +\\)?" ;; Stats cookies can be stuck to body. "\\(?:\\[[0-9%%/]+\\] *\\)*" "\\(%s\\)" -- 2.25.1 --=-=-=--