[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#62704: 30.0.50; treesit-install-language-grammar should accept an ar
From: |
Yuan Fu |
Subject: |
bug#62704: 30.0.50; treesit-install-language-grammar should accept an arg to indicate the installation path. |
Date: |
Wed, 12 Apr 2023 00:06:44 -0700 |
Nasy <nasyxx@gmail.com> writes:
> Hi,
>
> In treesit.el, the ~treesit-install-language-grammar~ function installs
> the grammar to the default path of
> ~treesit--install-language-grammar-1~, which is inconvenient for users
> who want to install the grammar to a custom path. Adding an optional
> argument =PATH= to this function and changing the line below would be
> better.
>
> (condition-case err
> (apply #'treesit--install-language-grammar-1
> ;; The nil is OUT-DIR.
> - (cons nil recipe))
> + (cons PATH recipe))
> (error
Fair enough. I added a prompt at the end that asks for the target
directory. Please give it a try (I didn’t test it :-)
Yuan