From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Dmitry Gutov Newsgroups: gmane.emacs.bugs Subject: bug#74610: 31.0.50; Submitting mhtml-ts-mode, treesitter alternative to mhtml-mode Date: Thu, 5 Dec 2024 18:51:55 +0200 Message-ID: <97c6e669-b9a2-4e1c-b224-227bb65de0fd@gutov.dev> References: <3532547.LZWGnKmheA@fedora> <22104588.4csPzL39Zc@3-191.divsi.unimi.it> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="4941"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mozilla Thunderbird To: Vincenzo Pupillo , 74610@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Thu Dec 05 17:53:31 2024 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1tJF6Y-0001Ay-92 for geb-bug-gnu-emacs@m.gmane-mx.org; Thu, 05 Dec 2024 17:53:31 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tJF6K-0007hV-Gg; Thu, 05 Dec 2024 11:53:16 -0500 Original-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 1tJF6G-0007h5-CO for bug-gnu-emacs@gnu.org; Thu, 05 Dec 2024 11:53:12 -0500 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1tJF66-0003mV-Br for bug-gnu-emacs@gnu.org; Thu, 05 Dec 2024 11:53:12 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=In-Reply-To:From:References:MIME-Version:Date:To:Subject; bh=6teG8DK9ot3T1ruqcwtAG77vCP+PYhnVREjdnM5QF98=; b=l5CaYOY7SMsqCia3ErjUWtOn2J9iFXL99swLJcjoy22WrPW6lQDsQvDQ31FPlJDLlBpFo10MhMYEvZoVG8pg3N5s9lLVa3FNxRbegpknoyGNdY9MpDsmfn5ZjHZ2f2wRtZQ9aTmhFdMEjhZYS253ZLvn/ZrcSWMKrKMG08cv225WLi8pzaXf3sYIDEE5Qbfz1DQ40MxKpvHsO8QOhLHQs+qB8FaK9EWF+C3k89yENYG5eIgZBuhWF1H3SurHMVpiQkXhN27HB4YZXckCtt0LEDLU2gp43cl54LpLWWY+yEC3DnWY4aJOJ3Mr72PCFcGeKJf/yNIdvIUWXbDyKvFsVA==; Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1tJF65-0007Hk-UV for bug-gnu-emacs@gnu.org; Thu, 05 Dec 2024 11:53:01 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Dmitry Gutov Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 05 Dec 2024 16:53:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 74610 X-GNU-PR-Package: emacs Original-Received: via spool by 74610-submit@debbugs.gnu.org id=B74610.173341752927909 (code B ref 74610); Thu, 05 Dec 2024 16:53:01 +0000 Original-Received: (at 74610) by debbugs.gnu.org; 5 Dec 2024 16:52:09 +0000 Original-Received: from localhost ([127.0.0.1]:40470 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tJF5F-0007G3-Bx for submit@debbugs.gnu.org; Thu, 05 Dec 2024 11:52:09 -0500 Original-Received: from fhigh-a2-smtp.messagingengine.com ([103.168.172.153]:50561) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tJF5B-0007FP-P6 for 74610@debbugs.gnu.org; Thu, 05 Dec 2024 11:52:08 -0500 Original-Received: from phl-compute-09.internal (phl-compute-09.phl.internal [10.202.2.49]) by mailfhigh.phl.internal (Postfix) with ESMTP id A1A2E1140151; Thu, 5 Dec 2024 11:51:59 -0500 (EST) Original-Received: from phl-mailfrontend-02 ([10.202.2.163]) by phl-compute-09.internal (MEProxy); Thu, 05 Dec 2024 11:51:59 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gutov.dev; h=cc :content-transfer-encoding:content-type:content-type:date:date :from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:subject:subject:to:to; s=fm3; t=1733417519; x=1733503919; bh=6teG8DK9ot3T1ruqcwtAG77vCP+PYhnVREjdnM5QF98=; b= IiajMP3JpV/3knqceeD3dm6qjFjb31jMH20/OgR2lZx454O97Y66QCMQw1hR4e4k di17lt9/5fYF+yXofS8sX08n3PcN4VVsBSHCrtUVBWhkumBiX4WioPjeXC1swyT1 qDVkKdC41f3qQFVUDFCUUGrOnOiGP1LXvlD2QbwKXn+oFVQnUY85pNsOc70sxdin x5u7Y1FHAn3OVhZHxKYIGgt1rzSv4DaVQPw3F6PmExqpErgEbg7GpUBeXnQUhsXG gf9U9AtStcwwrM1hnxbav/85iojihjZaFWd292Se1/PasirTxBNqZFOm/WA3MJkl IOY8FhtWquPZb7+FHuqPMQ== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :content-type:date:date:feedback-id:feedback-id:from:from :in-reply-to:in-reply-to:message-id:mime-version:references :reply-to:subject:subject:to:to:x-me-proxy:x-me-sender :x-me-sender:x-sasl-enc; s=fm1; t=1733417519; x=1733503919; bh=6 teG8DK9ot3T1ruqcwtAG77vCP+PYhnVREjdnM5QF98=; b=kW0wi+uNaqEDzXIJr xbP48JREDNM/iMUA+MuJpW2nPhSeouNfYHabI+jCqlQdo18Ba8zdMN+TiyE0Rl8V GG/nfsa+V29CYHU7+SkCM3iVhDonHyyc0xCtReoPmVkacUeMoYyZP61m1HUoj7/R SnMFKs43tAQulOKU5PqBvq0GycREmbepsV4FMqwk9r28xhCuu2bkmzoCd9ZL1Rs9 xNJWwWe7a5K4XjNaoZwYR9UykFEgTPoxSID6k5JoESBqPGdbMzVLn7Az1w56JBuG ejx2nZl6chOqMdo1WGBuXb6loerOplcjXGSsvrEy1K9AhuVa1q6sy2Ekcbn5KzxN 0a5GA== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeefuddrieejgdelvdcutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpggftfghnshhusghstghrihgsvgdpuffr tefokffrpgfnqfghnecuuegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnth hsucdlqddutddtmdenucfjughrpefkffggfgfuvfhfhfgjtgfgsehtkeertddtvdejnecu hfhrohhmpeffmhhithhrhicuifhuthhovhcuoegumhhithhrhiesghhuthhovhdruggvvh eqnecuggftrfgrthhtvghrnhepheekfedtveetkeehheffkedtffevfeffieellefhgfeg uefhtdekfeeuveeiudfgnecuffhomhgrihhnpehgihhthhhusgdrtghomhenucevlhhush htvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpegumhhithhrhiesghhu thhovhdruggvvhdpnhgspghrtghpthhtohepvddpmhhouggvpehsmhhtphhouhhtpdhrtg hpthhtohepvhdrphhuphhilhhlohesghhmrghilhdrtghomhdprhgtphhtthhopeejgeei uddtseguvggssghughhsrdhgnhhurdhorhhg X-ME-Proxy: Feedback-ID: i07de48aa:Fastmail Original-Received: by mail.messagingengine.com (Postfix) with ESMTPA; Thu, 5 Dec 2024 11:51:58 -0500 (EST) Content-Language: en-US In-Reply-To: <22104588.4csPzL39Zc@3-191.divsi.unimi.it> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:296475 Archived-At: Hi Vincenzo, On 04/12/2024 12:47, Vincenzo Pupillo wrote: >> Do you foresee cases for when html-ts-mode would be preferred by the >> user instead of this advanced mhtml-ts-mode? > For everyday use mhtml-ts-mode is better, just like mhtml-mode (which has been > the default for html editing for a while now). > >> Or maybe the former is >> better in its current shape when used by e.g. php-ts-mode? > Yes, personally I think that major modes that handle (for tree-sitters) only > one language are easier to put together at the moment. It's Lego vs. > Playmobil. > We are in an experimental phase, like all other editors. > See https://github.com/helix-editor/helix/pull/1170#issuecomment-997294090 > In some ways, by having a different approach from other editors, we have a > greater degree of flexibility IMHO. Makes sense, thanks. >> In other words, I'm wondering why not update the existing mode with >> sub-parsers rather than add a new one. html-mode had such a reason - >> it's quite old, and has been used in various placed the way it is now >> (including multi-mode packages). But ts modes don't work too well with >> multi-mode packages, not currently anyway. > > It's something I've thought about but haven't tried yet. > One of the themes of the email thread (on emacs-devel) was to have a simple > multi language major mode that was also a sort of “user's guide.” I though the updated html-ts-mode could be that mode. Anyway, good to hear that this alternative had been given consideration.