GNU bug report logs - #71562
treesit-install-language-grammar fails to install typescript

Previous Next

Package: emacs;

Reported by: Steinar Bang <sb <at> dod.no>

Date: Fri, 14 Jun 2024 18:19:02 UTC

Severity: normal

Merged with 71717

Found in version 30.0.50

Full log


Message #47 received at 71562 <at> debbugs.gnu.org (full text, mbox):

From: Dmitry Gutov <dmitry <at> gutov.dev>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: casouri <at> gmail.com, sb <at> dod.no, 71562 <at> debbugs.gnu.org
Subject: Re: bug#71562: treesit-install-language-grammar fails to install
 typescript
Date: Thu, 20 Jun 2024 18:03:32 +0300
On 20/06/2024 14:31, Eli Zaretskii wrote:

>>> And what do you think should happen next?  Or where's the problem in
>>> the above 3 steps?
>>
>> Next he presses RET a few times and the installation fails.
> 
> Why would it fail, if my suggestion is implemented?

Because your suggestion is for the case where Bob specifies 'typescript' 
on step 3.

>> If we added two entries to treesit-language-source-alist by default,
>> OTOH (one for typescript, and another for tsx), then Bob would be able
>> to install the grammar easily.
> 
> But then we'd need to maintain a DB of all the "abnormal" repositories
> (and there a few of them),

There are not too many of them, and out of those TypeScript (and TSX 
with it) is more popular than most of the others as a programming 
language. So even if we add these two it wouldn't follow that we must 
have the rest.

> which is less reliable.

I suppose we could do both - both update the recipe, and scan the 
directory tree for files named parser.c.

If we aren't concerned about side-effects, such as for example when the 
user wanted to stay on the previous version of the tsx grammar they had 
installed (because the major mode doesn't work with the newer one), but 
they need to update the typescript grammar, and the tsx grammar is 
overwritten in the process too.




This bug report was last modified 362 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.