From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#71380: 30.0.50; Submitting php-ts-mode, new major mode for php Date: Thu, 06 Jun 2024 09:58:11 +0300 Message-ID: <86cyouimm4.fsf@gnu.org> References: <3686989.dWV9SEqChM@3-191.divsi.unimi.it> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="24072"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 71380@debbugs.gnu.org To: Vincenzo Pupillo , Stefan Monnier , Philip Kaludercic , Yuan Fu Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Thu Jun 06 08:58:58 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 1sF75O-00064C-25 for geb-bug-gnu-emacs@m.gmane-mx.org; Thu, 06 Jun 2024 08:58:58 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1sF75H-0002JP-2D; Thu, 06 Jun 2024 02:58:51 -0400 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 1sF75E-0002JE-RL for bug-gnu-emacs@gnu.org; Thu, 06 Jun 2024 02:58:49 -0400 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 1sF75E-0000Y1-0Y for bug-gnu-emacs@gnu.org; Thu, 06 Jun 2024 02:58:48 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1sF75S-0002df-5p for bug-gnu-emacs@gnu.org; Thu, 06 Jun 2024 02:59:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 06 Jun 2024 06:59:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 71380 X-GNU-PR-Package: emacs Original-Received: via spool by 71380-submit@debbugs.gnu.org id=B71380.171765711810083 (code B ref 71380); Thu, 06 Jun 2024 06:59:02 +0000 Original-Received: (at 71380) by debbugs.gnu.org; 6 Jun 2024 06:58:38 +0000 Original-Received: from localhost ([127.0.0.1]:43742 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sF754-0002cY-52 for submit@debbugs.gnu.org; Thu, 06 Jun 2024 02:58:38 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:50426) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sF752-0002bh-8q for 71380@debbugs.gnu.org; Thu, 06 Jun 2024 02:58:36 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sF74h-0000WI-QB; Thu, 06 Jun 2024 02:58:15 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=FVXjAvd9nrpo81p9yrhc2lyyM/0t2cOmelYeOVPS3Pg=; b=CecFcHrKziF6 7fVihnByjn/Qrg51QAgCmZ0LWGjNbAlc2aWUqdTv9jiNTW0ZTug8hQXFiIRdBkQbsgpHQHNv7Ghvi el5Aw6f99XzcwQxR/db1DQO2qq3dbAHHGK9nw2IRvQwqRcjbQRlmaaivQr7re9t3QexuLjNURllrG UXTvVJE8vkoD8tUmnX7ip1Dx1oh1vzIc8k68wyrxlQCDnI8Aog+TWSL2CEyOzdTGDbKMn57ztNvwR ImGnizoSIjGaW9nCetjkQmBqfVPnYayJRIHnmmMRdtalOXJ5bUYmsG7Sd5vwG2aD8IwMaYYVIp7WA Fd+SNzPvB5V4XLPLOgQG5A==; In-Reply-To: <3686989.dWV9SEqChM@3-191.divsi.unimi.it> (message from Vincenzo Pupillo on Wed, 05 Jun 2024 15:59:20 +0200) 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:286666 Archived-At: > From: Vincenzo Pupillo > Date: Wed, 05 Jun 2024 15:59:20 +0200 > > I would like to submit php-ts-mode. > This major mode this major mode, in addition to font-lock for PHP implements the following features: > * font-lock for html, javascript, css and phpdoc. > * six different indentation styles (PSR, PEAR, Zend, Drupal, Wordpress, Symfony). > * Imenu > * Flymake > * Which-function > * a helper function to simplify the installation of parsers, in versions used to develop major-mode > * PHP built-in server support > * Shell interaction: execute PHP code in an inferior PHP process. Thanks, I added Stefan, Philip and Yuan to the discussion, in case they have comments. > +--- > +*** New major mode 'php-ts-mode'. > +A major mode based on the tree-sitter library for editing This seems to be an incomplete sentence. Also, I think we should add PHP to the list of modes in the "Program Modes" node of the Emacs user manual. > +(defun php-ts-mode-install-parsers () > + "Install all the required treesitter parser. ^^^^^^ "parsers", in plural. > +`php-ts-mode--language-source-alist' define which parsers to install." ^^^^^^ "defines". > +(defcustom php-ts-mode-indent-offset 4 > + "Number of spaces for each indentation step (default) in `php-ts-mode'." ^^^^^^ "columns", I guess? And what does "(default)" mean here? > +(defcustom php-ts-mode-js-css-indent-offset html-ts-mode-indent-offset > + "JavaScript and CSS indent spaces related to the