From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Re: Tree-sitter introduction documentation Date: Fri, 30 Dec 2022 19:25:22 -0500 Message-ID: References: <83edszjslp.fsf@gnu.org> <87tu1vxs3a.fsf@ledu-giraud.fr> <831qozjob7.fsf@gnu.org> <87cz8jxoat.fsf@ledu-giraud.fr> <83wn6ri7pn.fsf@gnu.org> <5e0a3185-de82-b339-0fa2-956779e63d6f@cornell.edu> <868rj6vfep.fsf@gmail.com> <4895891b-e5ea-9c37-f51b-df2e479ee758@yandex.ru> <83y1qt11xq.fsf@gnu.org> <9eb013da-d0fc-8e17-c6e3-1e8f913aebfa@yandex.ru> <83pmc50xxc.fsf@gnu.org> <71cfe4e8-3bb8-b0a6-9be5-8c0a6d92cfab@yandex.ru> <83h6xg29z3.fsf@gnu.org> <87wn6cyey5.fsf@posteo.net> <787B1EB4-1925-4679-8747-449DCD685432@gmail.com> <83y1qo6h7a.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="21879"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Cc: Eli Zaretskii , Philip Kaludercic , dgutov@yandex.ru, theophilusx@gmail.com, emacs-devel@gnu.org To: Yuan Fu Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Sat Dec 31 01:26:14 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 1pBPhR-00056s-1Z for ged-emacs-devel@m.gmane-mx.org; Sat, 31 Dec 2022 01:26:09 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pBPgq-0005PI-S7; Fri, 30 Dec 2022 19:25:32 -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 1pBPgn-0005Os-QC for emacs-devel@gnu.org; Fri, 30 Dec 2022 19:25:29 -0500 Original-Received: from mailscanner.iro.umontreal.ca ([132.204.25.50]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pBPgl-0005PP-TA; Fri, 30 Dec 2022 19:25:29 -0500 Original-Received: from pmg3.iro.umontreal.ca (localhost [127.0.0.1]) by pmg3.iro.umontreal.ca (Proxmox) with ESMTP id 1749F4423BF; Fri, 30 Dec 2022 19:25:26 -0500 (EST) Original-Received: from mail01.iro.umontreal.ca (unknown [172.31.2.1]) by pmg3.iro.umontreal.ca (Proxmox) with ESMTP id 93DCE4423BC; Fri, 30 Dec 2022 19:25:24 -0500 (EST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=iro.umontreal.ca; s=mail; t=1672446324; bh=2DYSVdj12jlFhT/u/FFaM0LSzHGm1ONj42DCKS6iH1I=; h=From:To:Cc:Subject:In-Reply-To:References:Date:From; b=JclnkAffaTE6QELlt4ay9mUS2TQWBgLiSMCst/X7URyl0qKk+oBViIcb9c/6e8ct6 NpbfWOqSfjrT1nsehhx0WiiGIKrbK2TQrnpYqt2WwPwU7Vq7A7bPekYKx7uxcPkuvs QWwALY3jEcdwsGupxSlRJCZTqFOiViJwnAzpU/+KazZeQnXHuxrKH/DaiEosmzJuVc PEA/A4qL2ONb4z8Y1vfRVWnl+cVLuVnu8q0HILF5cAL22U+0sL03l08w0F6XA2jHaD TNNm0u4J5x0zOExTFPku08Gnxe4kfF3o02ekMmT5U4uS0WP0RxvHR1US3BrcC3rZ1u cusY2M4UKA3yA== Original-Received: from pastel (unknown [45.72.200.228]) by mail01.iro.umontreal.ca (Postfix) with ESMTPSA id 1DEF51201BF; Fri, 30 Dec 2022 19:25:24 -0500 (EST) In-Reply-To: (Yuan Fu's message of "Fri, 30 Dec 2022 16:03:42 -0800") Received-SPF: pass client-ip=132.204.25.50; envelope-from=monnier@iro.umontreal.ca; helo=mailscanner.iro.umontreal.ca X-Spam_score_int: -42 X-Spam_score: -4.3 X-Spam_bar: ---- X-Spam_report: (-4.3 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action 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-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:302144 Archived-At: >> Why "--depth 1"? This should be a defcustom, and the default should >> be to clone the full repository, IMO. Also, what about updating the >> library when it is already installed, and the Git repository already >> exists for it? Or are we going to clone anew each time and them >> remove the repository? that could make its cloning be slow in some >> cases. > > Since the purpose of this command is to install the grammar, why would we > want a full clone? Maybe it doesn't matter very much but: - I suspect most of those grammars have a fairly limited history, so I'd expect the savings from `--depth 1` to be rather small. - And ... [...checking the previous point's theory...] Wow, that's really weird: they do have a fairly short history (like ~200 commits) but the full clone is *much* larger than the `--depth 1` clone. I guess it's because they store the generated `.c` file in there and the small changes in the source cause much larger changes in the generated file. > I wanted to keep it simple, synchronous, and quiet, and didn=E2=80=99t th= ought > much about it. I think we should default to asynchonous operations as much as possible. Stefan