Juri Linkov <juri@HIDDEN>
to control <at> debbugs.gnu.org
.
Full text available.Received: (at 78892) by debbugs.gnu.org; 25 Jun 2025 18:52:02 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Wed Jun 25 14:52:02 2025 Received: from localhost ([127.0.0.1]:39469 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1uUVE1-0007qy-Fc for submit <at> debbugs.gnu.org; Wed, 25 Jun 2025 14:52:02 -0400 Received: from relay9-d.mail.gandi.net ([2001:4b98:dc4:8::229]:49395) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from <juri@HIDDEN>) id 1uUVDx-0007pC-82; Wed, 25 Jun 2025 14:51:58 -0400 Received: by mail.gandi.net (Postfix) with ESMTPSA id 9526841C7B; Wed, 25 Jun 2025 18:51:46 +0000 (UTC) From: Juri Linkov <juri@HIDDEN> To: James Cherti <contact@HIDDEN> Subject: Re: bug#78892: [PATCH] Fix yaml-ts-mode comment-start-skip to improve commenting/uncommenting In-Reply-To: <827317d2-c5a9-468e-a04c-b433720f0685@HIDDEN> Organization: LINKOV.NET References: <c9197c28-c5d3-425c-a8d1-9723680d6a40@HIDDEN> <8734boicfa.fsf@HIDDEN> <827317d2-c5a9-468e-a04c-b433720f0685@HIDDEN> Date: Wed, 25 Jun 2025 21:50:38 +0300 Message-ID: <87wm8zd5a9.fsf@HIDDEN> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/31.0.50 (x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain X-GND-State: clean X-GND-Score: 0 X-GND-Cause: gggruggvucftvghtrhhoucdtuddrgeeffedrtddvgddvfeehgecutefuodetggdotefrodftvfcurfhrohhfihhlvgemucfitefpfffkpdcuggftfghnshhusghstghrihgsvgenuceurghilhhouhhtmecufedtudenucenucfjughrpefhvfevufgjohhffffkfgggtgesthdtredttdertdenucfhrhhomheplfhurhhiucfnihhnkhhovhcuoehjuhhriheslhhinhhkohhvrdhnvghtqeenucggtffrrghtthgvrhhnpeffgeetfeevlefhleejfeeuheeiudeitdffhfdutdekfeffgffhveehteegueekheenucfkphepledurdduvdelrddutddtrdejjeenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepihhnvghtpeeluddruddvledruddttddrjeejpdhhvghlohepmhgrihhlrdhgrghnughirdhnvghtpdhmrghilhhfrhhomhepjhhurhhisehlihhnkhhovhdrnhgvthdpnhgspghrtghpthhtohepfedprhgtphhtthhopegtohhnthhrohhlseguvggssghughhsrdhgnhhurdhorhhgpdhrtghpthhtohepjeekkeelvdesuggvsggsuhhgshdrghhnuhdrohhrghdprhgtphhtthhopegtohhnthgrtghtsehjrghmvghstghhvghrthhirdgtohhm X-GND-Sasl: juri@HIDDEN X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 78892 Cc: 78892 <at> debbugs.gnu.org X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -1.7 (-) close 78892 31.0.50 thanks > For some reason, "#+\s-*" causes issues with commenting and > uncommenting, whereas "#+ *" does not. > > The pattern "#+ *" is sufficient for YAML, as the YAML > specification disallows tabs and permits only spaces. Agreed. So now pushed and closed as fixed.
bug-gnu-emacs@HIDDEN
:bug#78892
; Package emacs
.
Full text available.Received: (at 78892) by debbugs.gnu.org; 25 Jun 2025 18:19:21 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Wed Jun 25 14:19:21 2025 Received: from localhost ([127.0.0.1]:39393 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1uUUiO-0002GC-PF for submit <at> debbugs.gnu.org; Wed, 25 Jun 2025 14:19:21 -0400 Received: from hamster.birch.relay.mailchannels.net ([23.83.209.80]:43165) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from <contact@HIDDEN>) id 1uUUiI-0002FG-Kw for 78892 <at> debbugs.gnu.org; Wed, 25 Jun 2025 14:19:18 -0400 X-Sender-Id: dreamhost|x-authsender|contact@HIDDEN Received: from relay.mailchannels.net (localhost [127.0.0.1]) by relay.mailchannels.net (Postfix) with ESMTP id C19E08A5CBC; Wed, 25 Jun 2025 18:19:12 +0000 (UTC) Received: from pdx1-sub0-mail-a202.dreamhost.com (trex-green-9.trex.outbound.svc.cluster.local [100.100.12.93]) (Authenticated sender: dreamhost) by relay.mailchannels.net (Postfix) with ESMTPA id 0D8428A5D09; Wed, 25 Jun 2025 18:19:12 +0000 (UTC) ARC-Seal: i=1; s=arc-2022; d=mailchannels.net; t=1750875552; a=rsa-sha256; cv=none; b=duwUV8uwgFebT/7xWSdAgRQfH9TCcMYPj9HNxgHVx1OiJs5AzRo52fhkIZO356n+u2YKkI UMTUBfp9RE6AMIjPxqjZT0LiN2V/MAYKzgRZIOSx5HErBm5i0hJ9/OUwE8zyGkKhRFeUBo m7+o0wUaZSsqLvFPuYDtrFqV4N8E5wbMjOdCEezVDWdgXymBYj+Z9Clch137KbPjPIWmur hmeLzqi7f4yv9DIo6L7EvCOdN2g3+AQ2t8OgS/n8osgO3CBGsEExe8mgeaEfosAktvvbWx o09eICWjF6ma6wnz8I780M23cyH7mYBLryh2TER941SlmoR6WkiZx3gNJedJXg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=mailchannels.net; s=arc-2022; t=1750875552; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=pdUdPo3WWiBtliVHtDfTWk1/R2QGKndSDZApNJ44vbw=; b=FgVaW+//ySyLHFs4hoBR7RX3AldjYNvDpcg2DlPfsY2m2sS5aUJvx4KCwX3EzMTsSdcVDn OROxLTi7xwOY0++8B6Jt4Y7XkpPq02idNTkWSMEAk/yxw/CuaN/DQtB/n0QhA0uVP7PCif 0tjq8DSMDbgNRMuKMgkEf9LdN9pjN2fwTv6n0tBNb9AtYx3xhhsUXVSnjrA/dKy5QE2FEl TmNc2Cnut2ltvna4i3oyhFlxwgELxpzL4g/4SuPtqhhYqbgwrKmdG6EJadm4ciitxNF9pw lFnntsbEqUZ10XoeYrJTI5It+B1XpGeIqyHIKnJcnLORs0fN+O7Kkw4ckaJwYg== ARC-Authentication-Results: i=1; rspamd-6597f9cdc7-r52d8; auth=pass smtp.auth=dreamhost smtp.mailfrom=contact@HIDDEN X-Sender-Id: dreamhost|x-authsender|contact@HIDDEN X-MC-Relay: Neutral X-MailChannels-SenderId: dreamhost|x-authsender|contact@HIDDEN X-MailChannels-Auth-Id: dreamhost X-Relation-Bottle: 3413c52a6b947de5_1750875552271_3967070637 X-MC-Loop-Signature: 1750875552271:1599887321 X-MC-Ingress-Time: 1750875552271 Received: from pdx1-sub0-mail-a202.dreamhost.com (pop.dreamhost.com [64.90.62.162]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384) by 100.100.12.93 (trex/7.1.3); Wed, 25 Jun 2025 18:19:12 +0000 Received: from [192.168.5.23] (24-212-139-93.cable.teksavvy.com [24.212.139.93]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: contact@HIDDEN) by pdx1-sub0-mail-a202.dreamhost.com (Postfix) with ESMTPSA id 4bS97g51dqz99; Wed, 25 Jun 2025 11:19:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=jamescherti.com; s=dreamhost; t=1750875551; bh=pdUdPo3WWiBtliVHtDfTWk1/R2QGKndSDZApNJ44vbw=; h=Date:Subject:To:Cc:From:Content-Type:Content-Transfer-Encoding; b=T/WEo40sIIw0I6OtHV71vOrcaaeD4t4/IIq4tLURLcYKzWlpwKCacAg9A52nqLbPQ 95Xk+tkFcQ18nNLvJu+SNkDnNJyy9PGMxSbr1LYUP73w1QAb2bUPZyaFK5UtzgMyX6 3HZ/+haK1U5V61pTvqCMK8fEkEtJ0hG39WClK5yj5eazgon0767LSQVSBQkaQ/2+Pb MmxF5UrCseSip5mSgR94YIplOsN1tzK9DJfaaUZLdLjLq80mEti6CMThYPVKE6XnSf /d6bXO7NI/Xa0mWZzR3mwMmonDnUXKu1wDGVb78tm+bwhIPHprBYnj6emg3jFq7G/V 1QNNjoVNewZ9Q== Message-ID: <827317d2-c5a9-468e-a04c-b433720f0685@HIDDEN> Date: Wed, 25 Jun 2025 14:19:10 -0400 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: bug#78892: [PATCH] Fix yaml-ts-mode comment-start-skip to improve commenting/uncommenting To: Juri Linkov <juri@HIDDEN> References: <c9197c28-c5d3-425c-a8d1-9723680d6a40@HIDDEN> <8734boicfa.fsf@HIDDEN> Content-Language: en-US From: James Cherti <contact@HIDDEN> In-Reply-To: <8734boicfa.fsf@HIDDEN> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 78892 Cc: 78892 <at> debbugs.gnu.org X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -1.0 (-) Hello Juri, For some reason, "#+\s-*" causes issues with commenting and uncommenting, whereas "#+ *" does not. The pattern "#+ *" is sufficient for YAML, as the YAML specification disallows tabs and permits only spaces. -- James Cherti GitHub: https://github.com/jamescherti Website: https://www.jamescherti.com/ On 2025-06-25 13:13, Juri Linkov wrote: >> As demonstrated, some block items starting with '-' remain >> commented, causing inconsistent comment handling in YAML >> indented blocks. >> >> This patch ensures the entire comment line, including >> leading '-' characters, is properly toggled by modifying >> the comment-start-skip regular expression. > >> - (setq-local comment-start-skip "#+\\s-*") >> + (setq-local comment-start-skip "#+ *") > > Since yaml-mode uses "#+ *", yaml-ts-mode could use the same. > So this patch could be pushed for compatibility with yaml-mode. > > But I really don't see a difference between "#+\\s-*" and "#+ *". > One matches any whitespace, and another just the space character. > I don't understand how this could affect block items starting with '-'. > While trying your test case, I can't reproduce the problem: > everything is uncommented correctly. > > >
bug-gnu-emacs@HIDDEN
:bug#78892
; Package emacs
.
Full text available.Received: (at 78892) by debbugs.gnu.org; 25 Jun 2025 17:17:44 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Wed Jun 25 13:17:44 2025 Received: from localhost ([127.0.0.1]:38420 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1uUTkm-0002UW-Fs for submit <at> debbugs.gnu.org; Wed, 25 Jun 2025 13:17:44 -0400 Received: from relay8-d.mail.gandi.net ([2001:4b98:dc4:8::228]:53247) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from <juri@HIDDEN>) id 1uUTkj-0002T6-QJ for 78892 <at> debbugs.gnu.org; Wed, 25 Jun 2025 13:17:42 -0400 Received: by mail.gandi.net (Postfix) with ESMTPSA id BCC6144457; Wed, 25 Jun 2025 17:17:32 +0000 (UTC) From: Juri Linkov <juri@HIDDEN> To: James Cherti <contact@HIDDEN> Subject: Re: bug#78892: [PATCH] Fix yaml-ts-mode comment-start-skip to improve commenting/uncommenting In-Reply-To: <c9197c28-c5d3-425c-a8d1-9723680d6a40@HIDDEN> Organization: LINKOV.NET References: <c9197c28-c5d3-425c-a8d1-9723680d6a40@HIDDEN> Date: Wed, 25 Jun 2025 20:13:13 +0300 Message-ID: <8734boicfa.fsf@HIDDEN> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/31.0.50 (x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain X-GND-State: clean X-GND-Score: 0 X-GND-Cause: gggruggvucftvghtrhhoucdtuddrgeeffedrtddvgddvfeefgecutefuodetggdotefrodftvfcurfhrohhfihhlvgemucfitefpfffkpdcuggftfghnshhusghstghrihgsvgenuceurghilhhouhhtmecufedtudenucenucfjughrpefhvfevufgjohhffffkfgggtgesthdtredttdertdenucfhrhhomheplfhurhhiucfnihhnkhhovhcuoehjuhhriheslhhinhhkohhvrdhnvghtqeenucggtffrrghtthgvrhhnpeffgeetfeevlefhleejfeeuheeiudeitdffhfdutdekfeffgffhveehteegueekheenucfkphepledurdduvdelrddutddtrdejjeenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepihhnvghtpeeluddruddvledruddttddrjeejpdhhvghlohepmhgrihhlrdhgrghnughirdhnvghtpdhmrghilhhfrhhomhepjhhurhhisehlihhnkhhovhdrnhgvthdpnhgspghrtghpthhtohepvddprhgtphhtthhopeejkeekledvseguvggssghughhsrdhgnhhurdhorhhgpdhrtghpthhtoheptghonhhtrggtthesjhgrmhgvshgthhgvrhhtihdrtghomh X-GND-Sasl: juri@HIDDEN X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 78892 Cc: 78892 <at> debbugs.gnu.org X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -1.7 (-) > As demonstrated, some block items starting with '-' remain > commented, causing inconsistent comment handling in YAML > indented blocks. > > This patch ensures the entire comment line, including > leading '-' characters, is properly toggled by modifying > the comment-start-skip regular expression. > - (setq-local comment-start-skip "#+\\s-*") > + (setq-local comment-start-skip "#+ *") Since yaml-mode uses "#+ *", yaml-ts-mode could use the same. So this patch could be pushed for compatibility with yaml-mode. But I really don't see a difference between "#+\\s-*" and "#+ *". One matches any whitespace, and another just the space character. I don't understand how this could affect block items starting with '-'. While trying your test case, I can't reproduce the problem: everything is uncommented correctly.
bug-gnu-emacs@HIDDEN
:bug#78892
; Package emacs
.
Full text available.Received: (at submit) by debbugs.gnu.org; 24 Jun 2025 17:56:30 +0000 From debbugs-submit-bounces <at> debbugs.gnu.org Tue Jun 24 13:56:30 2025 Received: from localhost ([127.0.0.1]:47844 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1uU7sk-0004RE-3d for submit <at> debbugs.gnu.org; Tue, 24 Jun 2025 13:56:30 -0400 Received: from lists.gnu.org ([2001:470:142::17]:46944) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from <contact@HIDDEN>) id 1uU7sh-0004P3-Aj for submit <at> debbugs.gnu.org; Tue, 24 Jun 2025 13:56:28 -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 <contact@HIDDEN>) id 1uU7sB-0000rz-Tk for bug-gnu-emacs@HIDDEN; Tue, 24 Jun 2025 13:56:00 -0400 Received: from cyan.elm.relay.mailchannels.net ([23.83.212.47]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from <contact@HIDDEN>) id 1uU7s9-00033L-Rf for bug-gnu-emacs@HIDDEN; Tue, 24 Jun 2025 13:55:55 -0400 X-Sender-Id: dreamhost|x-authsender|contact@HIDDEN Received: from relay.mailchannels.net (localhost [127.0.0.1]) by relay.mailchannels.net (Postfix) with ESMTP id 0F400184A3B for <bug-gnu-emacs@HIDDEN>; Tue, 24 Jun 2025 17:55:50 +0000 (UTC) Received: from pdx1-sub0-mail-a218.dreamhost.com (trex-green-9.trex.outbound.svc.cluster.local [100.100.179.10]) (Authenticated sender: dreamhost) by relay.mailchannels.net (Postfix) with ESMTPA id AAC8F184D28 for <bug-gnu-emacs@HIDDEN>; Tue, 24 Jun 2025 17:55:49 +0000 (UTC) ARC-Seal: i=1; s=arc-2022; d=mailchannels.net; t=1750787749; a=rsa-sha256; cv=none; b=gfA1vgGNtYXe7k4BAGDgbfeQYyjKyJ7sufPpGhtZLrsUCZWnfQ+m72BNMhLx0HS7gRHohL tiRcx1LhOU0LBBsNZUP0nelxbW4tjMyBNXdbbw0r3XYdReZJ1JTPLbNTvHnXRX3igmwGJH KkPCxaHrH9h6VUdY8n6X0p6GffAJryKAp+ZfG1Z5mTj4HF3tzrfeJynAOBb6nM+XeuPQpO wKTkIKxkbSfXNbUbV4v1vACd2sAbFnaElXpgs8pB7+npgrFgfOFnWIQWD37ZvaYa72OHss 6GR2v91y5v52tcqfSEPUUaKxld0XGn/ht/643JyGO82Ph/4PN2HiwDeWvNsLbA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=mailchannels.net; s=arc-2022; t=1750787749; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: dkim-signature; bh=JeESxwSFOz1RmNzcXf1bE0BhbWnDqs3TVkMZIet3Tns=; b=YUK2xzshFxbz0T/7XG6QaJL5Bo5cNXP0hAKGTWrTIyu8CQm1Wm748ze2x6X9sWdGHjOtyG Mdzk1ssnTxu+O6BZ0VTczuXEIvfCFb7ZajvDdCookoBQjDH4xCwwR3m+R2ydp/DkFdla6N nGz5khdDtbxp60yKEGbCf0r8usp519KEdoeQEioBgcqBPimRcEKMqIxbudyajxEjzvyAY8 V+zlQYnn12yO8lxGDdByWoUD9BCDvuUaEUaZEdqKQc1r4bulN5loy241NZAF8n8wMlmZJ2 1aqDCpxyBjwyOXgY3TNFd3ByN/3b858HdxEH58dCrq3NAENqCIzJrU74EjyXGA== ARC-Authentication-Results: i=1; rspamd-679c59f89-kdswp; auth=pass smtp.auth=dreamhost smtp.mailfrom=contact@HIDDEN X-Sender-Id: dreamhost|x-authsender|contact@HIDDEN X-MC-Relay: Neutral X-MailChannels-SenderId: dreamhost|x-authsender|contact@HIDDEN X-MailChannels-Auth-Id: dreamhost X-Power-Drop: 6b82c4f832dfce77_1750787749907_894365780 X-MC-Loop-Signature: 1750787749907:3002285033 X-MC-Ingress-Time: 1750787749907 Received: from pdx1-sub0-mail-a218.dreamhost.com (pop.dreamhost.com [64.90.62.162]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384) by 100.100.179.10 (trex/7.1.3); Tue, 24 Jun 2025 17:55:49 +0000 Received: from [192.168.5.23] (24-212-139-93.cable.teksavvy.com [24.212.139.93]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: contact@HIDDEN) by pdx1-sub0-mail-a218.dreamhost.com (Postfix) with ESMTPSA id 4bRXg92g0PzGL for <bug-gnu-emacs@HIDDEN>; Tue, 24 Jun 2025 10:55:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=jamescherti.com; s=dreamhost; t=1750787749; bh=JeESxwSFOz1RmNzcXf1bE0BhbWnDqs3TVkMZIet3Tns=; h=Content-Type:Date:To:From:Subject; b=WdkbP4HBXtUEv0/37to+tIXnSaNOIGQQZxEWcvyHerSXqS+EdcZQj5NRu6iUHXdCw v4JRKhB+5+TsusVNuclVJ4mtS8ILShBvVMlHHqn6RCRWKXwBTkxayGRNDGP+IsTZcX SF8bHzhzGvFFloP0Uv8ZwZ/1bGmw6HH0ldVsPGJfGmtSaVE1eyYiN7slJeGuYDAI2Z pYBH1MroVAzNzOnarQDpfvxiBu1JC4OHcxHDjjr/tp7zMnR5BViRWJCJnff3QD9gxf oyOlSyG1S1WBrOv+22rRc1xK4g1nnNSC6WDBmDZV1rQlk9SgvlEuuLeYr/PAlOuLdp YcnAzSUD0DkYg== Content-Type: multipart/mixed; boundary="------------uOOaMa6OZVUQ7hiGun8Ovo48" Message-ID: <c9197c28-c5d3-425c-a8d1-9723680d6a40@HIDDEN> Date: Tue, 24 Jun 2025 13:55:48 -0400 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Content-Language: en-US To: bug-gnu-emacs@HIDDEN From: James Cherti <contact@HIDDEN> Subject: [PATCH] Fix yaml-ts-mode comment-start-skip to improve commenting/uncommenting Received-SPF: pass client-ip=23.83.212.47; envelope-from=contact@HIDDEN; helo=cyan.elm.relay.mailchannels.net 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, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, RCVD_IN_VALIDITY_SAFE_BLOCKED=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: 0.9 (/) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -0.1 (/) This is a multi-part message in MIME format. --------------uOOaMa6OZVUQ7hiGun8Ovo48 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit This patch resolves an issue in yaml-ts-mode where the comment-start-skip value caused some leading '-' characters to remain uncommented when using the comment-or-uncomment-region command on multiple indented YAML blocks. Reproduction steps: 1. Open a YAML file and switch the major mode to yaml-ts-mode. 2. Paste the following into that file: # - name: "Daily: script" # cron: # name: "script" # job: "{{ system_home }}/scripts/script.sh >/dev/null" # minute: "30" # hour: "3" # # - name: "Ensure directories exist" # file: # state: directory # path: "{{ item }}" # mode: '0755' # loop: # - "{{ system_home }}/logs" # - "{{ system_home }}/cache" # - "{{ system_home }}/tmp" # # - name: "Deploy configuration files" # ansible.builtin.template: # dest: "{{ system_home }}/config/{{ item }}" # src: "configs/{{ item }}" # mode: '0644' # loop: "{{ config_files }}" 3. Select the pasted text and invoke `M-x comment-or-uncomment-region`. 4. Issue observed after uncommenting: - name: "Daily: script" cron: name: "script" job: "{{ system_home }}/scripts/script.sh >/dev/null" minute: "30" hour: "3" # - name: "Ensure directories exist" file: state: directory path: "{{ item }}" mode: '0755' loop: - "{{ system_home }}/logs" - "{{ system_home }}/cache" - "{{ system_home }}/tmp" # - name: "Deploy configuration files" ansible.builtin.template: dest: "{{ system_home }}/config/{{ item }}" src: "configs/{{ item }}" mode: '0644' loop: "{{ config_files }}" As demonstrated, some block items starting with '-' remain commented, causing inconsistent comment handling in YAML indented blocks. This patch ensures the entire comment line, including leading '-' characters, is properly toggled by modifying the comment-start-skip regular expression. -- James Cherti GitHub: https://github.com/jamescherti Website: https://www.jamescherti.com/ --------------uOOaMa6OZVUQ7hiGun8Ovo48 Content-Type: text/x-patch; charset=UTF-8; name="0001-Fix-yaml-ts-mode-comment-start-skip.patch" Content-Disposition: attachment; filename="0001-Fix-yaml-ts-mode-comment-start-skip.patch" Content-Transfer-Encoding: base64 RnJvbSA3MTUzZWQ0ZGI1MDg1MzE0YjYwM2I1ZWQ3OGUxYzBkMDM4YTliYzY3IE1vbiBTZXAg MTcgMDA6MDA6MDAgMjAwMQpGcm9tOiBKYW1lcyBDaGVydGkgPGNvbnRhY3RAamFtZXNjaGVy dGkuY29tPgpEYXRlOiBUdWUsIDI0IEp1biAyMDI1IDEzOjI1OjQwIC0wNDAwClN1YmplY3Q6 IFtQQVRDSF0gRml4IHlhbWwtdHMtbW9kZSBjb21tZW50LXN0YXJ0LXNraXAgdG8gaW1wcm92 ZQogY29tbWVudGluZy91bmNvbW1lbnRpbmcKCiAgICAqIGxpc3AvdGV4dG1vZGVzL3lhbWwt dHMtbW9kZS5lbDogRml4ZWQgY29tbWVudC1zdGFydC1za2lwIHZhbHVlCiAgICAgIHRvIHJl c29sdmUgYW4gaXNzdWUgd2hlbiBjb21tZW50aW5nL3VuY29tbWVudGluZyB1c2luZwogICAg ICB0aGUgY29tbWVudC1vci11bmNvbW1lbnQtcmVnaW9uIGZ1bmN0aW9uLgogICAgICBUaGUg cHJldmlvdXMgY29tbWVudC1zdGFydC1za2lwIHZhbHVlIGxlZnQgc29tZSAiLSIgdW5jb21t ZW50ZWQKICAgICAgYWZ0ZXIgY29tbWVudGluZyBhbmQgdW5jb21tZW50aW5nIG11bHRpcGxl IFlBTUwgaW5kZW50ZWQgYmxvY2tzLgoKQ29weXJpZ2h0LXBhcGVyd29yay1leGVtcHQ6IHll cwotLS0KIGxpc3AvdGV4dG1vZGVzL3lhbWwtdHMtbW9kZS5lbCB8IDIgKy0KIDEgZmlsZSBj aGFuZ2VkLCAxIGluc2VydGlvbigrKSwgMSBkZWxldGlvbigtKQoKZGlmZiAtLWdpdCBhL2xp c3AvdGV4dG1vZGVzL3lhbWwtdHMtbW9kZS5lbCBiL2xpc3AvdGV4dG1vZGVzL3lhbWwtdHMt bW9kZS5lbAppbmRleCA1OGVkMDZkZTg4Ni4uY2FkYWUxOWFmMWUgMTAwNjQ0Ci0tLSBhL2xp c3AvdGV4dG1vZGVzL3lhbWwtdHMtbW9kZS5lbAorKysgYi9saXNwL3RleHRtb2Rlcy95YW1s LXRzLW1vZGUuZWwKQEAgLTE4NSwxMSArMTg1LDExIEBAIHlhbWwtdHMtbW9kZQogICAgIChz ZXRxIHRyZWVzaXQtcHJpbWFyeS1wYXJzZXIgKHRyZWVzaXQtcGFyc2VyLWNyZWF0ZSAneWFt bCkpCiAKICAgICA7OyBDb21tZW50cy4KICAgICAoc2V0cS1sb2NhbCBjb21tZW50LXN0YXJ0 ICIjICIpCiAgICAgKHNldHEtbG9jYWwgY29tbWVudC1lbmQgIiIpCi0gICAgKHNldHEtbG9j YWwgY29tbWVudC1zdGFydC1za2lwICIjK1xccy0qIikKKyAgICAoc2V0cS1sb2NhbCBjb21t ZW50LXN0YXJ0LXNraXAgIiMrICoiKQogCiAgICAgOzsgSW5kZW50YXRpb24uCiAgICAgKHNl dHEtbG9jYWwgaW5kZW50LXRhYnMtbW9kZSBuaWwpCiAKICAgICA7OyBGb250LWxvY2suCi0t IAoyLjUwLjAKCg== --------------uOOaMa6OZVUQ7hiGun8Ovo48--
James Cherti <contact@HIDDEN>
:bug-gnu-emacs@HIDDEN
.
Full text available.bug-gnu-emacs@HIDDEN
:bug#78892
; Package emacs
.
Full text available.
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997 nCipher Corporation Ltd,
1994-97 Ian Jackson.