From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Brian Newsgroups: gmane.emacs.devel Subject: Re: Call for volunteers: add tree-sitter support to major modes Date: Sun, 9 Oct 2022 14:36:22 +0000 Message-ID: References: <83czb1jrm3.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="13175"; mail-complaints-to="usenet@ciao.gmane.io" Cc: emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Sun Oct 09 16:55:02 2022 Return-path: Envelope-to: ged-emacs-devel@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 1ohXhm-0003G8-4r for ged-emacs-devel@m.gmane-mx.org; Sun, 09 Oct 2022 16:55:02 +0200 Original-Received: from localhost ([::1]:44536 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ohXhk-0004OV-Ps for ged-emacs-devel@m.gmane-mx.org; Sun, 09 Oct 2022 10:55:00 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:42704) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ohXPy-0005Zt-BT for emacs-devel@gnu.org; Sun, 09 Oct 2022 10:36:38 -0400 Original-Received: from mail-pf1-x443.google.com ([2607:f8b0:4864:20::443]:42863) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1ohXPw-0007k0-LD; Sun, 09 Oct 2022 10:36:37 -0400 Original-Received: by mail-pf1-x443.google.com with SMTP id i3so8785597pfk.9; Sun, 09 Oct 2022 07:36:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=IxvuhmcO7oNcMvb84ZWQVpTJTUqBti7y4NpesxUDi8w=; b=jL33kHDZpNu4T+HGpmC0dD42PBU6uOD79GE1dNbAfXfFPMi+sdrpF5sVqtbyzZI0w0 GCyvurutjcJYpmlSEynVUf+M+9/MsS3rTFHWWfXfMltJI3NLgAtfzz1+LnGzPg+7TcNo Cn1Wa8j0cd1CcEUQ7O3iKOTxIHCCZWl0tmo+1XzkhHDDVsiB1lfx1is81E3iNAMAy0Lj GNQDe4p+qS1p1KfkT6isHidrYEM+ejzFFyjyFOyniMl3621cOBi7vnXCb8QrV+tRl3sS dyN5fLJW41bgyV6AChuoHf1dkoUks48ZTyxjJ9FZr9XQqIlzAXgwxyARQ740wEzyPb4T DBmg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=IxvuhmcO7oNcMvb84ZWQVpTJTUqBti7y4NpesxUDi8w=; b=NlNVpRnDLXbfPMXleBNHCXgVEro8Vl8z1pjH3lEIpICUt9cH0UNokfdchF16nqiNRz kR3Ts7XU61pHrILbpxmlS/1KLCOJ35QOCkiwWdV5bh2icCMWeMSWMfJoHPFt+9uW9jxr bPinody19vc/qf4Yc9OO+/SbBIgOYpn/WVrvS/LGIwhc2CBX88lI8iSnxGhsrST9PkSM 0yh2HNuNv5nniuNFplHHcczbKIdpPuLMX91AggfX/TQVeI65RVxl5TSHUYXT2ba4a3CM h4bbP1lIAu566zcBhtEr5ci1Ae7Va1y1fIaOe4m7PH7S/7P+MV53UXmlMGXqUjedQv9J w/JA== X-Gm-Message-State: ACrzQf29/msRnq+v3oeRU2DxMRQ0LGt2EF9d7KQQ1YM6kAc/WUMWPbv5 /eaST62BITU3qFXiOGVVh7oRoJBulCLr3JSYYPSU4jq7vylqS1kyiuQ= X-Google-Smtp-Source: AMsMyM4PS702Y2mrXjIP4AkxvaYQQIQ99BAPKIZbAFTYjRj6lU0u//UKK3d9p4KzluLWyBrA5Z6cZn23Nkcb1fHAfNk= X-Received: by 2002:a63:474f:0:b0:459:5661:60ad with SMTP id w15-20020a63474f000000b00459566160admr12686612pgk.328.1665326193527; Sun, 09 Oct 2022 07:36:33 -0700 (PDT) In-Reply-To: <83czb1jrm3.fsf@gnu.org> Received-SPF: pass client-ip=2607:f8b0:4864:20::443; envelope-from=brian.miller.0235@gmail.com; helo=mail-pf1-x443.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, 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-Mailman-Approved-At: Sun, 09 Oct 2022 10:54:02 -0400 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:297277 Archived-At: Hello, I looked through some major modes and IIUC they already have an author assigned to them. I haven't seen this practice on other FLOSS projects I encountered GitHub, any pointers on how this process works on Emacs? TIA On Sun, Oct 9, 2022 at 9:03 AM Eli Zaretskii wrote: > > The Emacs 29 release branch is planned to be cut in about 1.5 months, > and we want tree-sitter support to be in Emacs 29. The Emacs Git > repository has a feature branch that integrates tree-sitter with > Emacs. That branch is being prepared for landing on master. However, > currently there's only one major-mode which can use tree-sitter > support on the branch: Python mode. We need to add tree-sitter > integration to more major modes, so that Emacs 29 could have > reasonably useful tree-sitter support options in at least the popular > major modes. > > This is a call for volunteers to work on adding tree-sitter support to > major modes beyond Python, and on improving the existing support in > Python mode. > > Some of the popular major modes for which we would like to see > tree-sitter support in Emacs 29 are: > > c-mode > c++-mode > emacs-lisp-mode > js-mode > js-json-mode > ruby-mode > shell-script-mode > > We probably won't have all of them by Emacs 29, but we hope to have at > least some. > > So if you are interested in enhancing your favorite major-mode with > tree-sitter support, and by doing that making Emacs 29 much better, > please checkout the feature/tree-sitter branch, and start working on > some mode(s). Tree-sitter support for a major-mode should include > enhancement of one or more of the following Emacs features: > > - font-lock > - indentation > - navigation (beginning-of-defun-function etc.) > - imenu > - which-func > - thing-at-point > > We think that font-lock is the absolute minimum, followed by > indentation. > > To help with this effort, Yuan Fu, who did most of the development on > this feature branch, wrote a document with guidance notes which aim to > help you implement tree-sitter support for the above features. You > will find that document and some other helpful documentation in the > admin/notes/tree-sitter directory and its subdirectories on the > branch. That directory also includes scripts for easy compilation of > tree-sitter language modules (which you will need to download from the > tree-sitter site). > > We hope that the existing support for Python can serve as working > example of how to add tree-sitter support for other major modes, and > together with the guidance document it will allow you to add support > for more modes with minimum effort. Don't hesitate to ask questions > if something is unclear or you need more advice. > > We hope volunteers will step forward in time to make tree-sitter > integration in Emacs 29 functional and useful. To avoid waste of > effort, please announce here on which major mode(s) you decided to > work. > > Thanks in advance. >