emacs-tree-sitter / elisp-tree-sitter

Emacs Lisp bindings for tree-sitter
https://emacs-tree-sitter.github.io
MIT License
816 stars 73 forks source link

tsc-dyn-get: allow to customize the path for tsc-dyn #122

Closed kiennq closed 3 years ago

kiennq commented 3 years ago

Allow to customize the path for tsc-dyn. Same problem with tree-sitter-langs, in Windows once dll has been loaded, we cannot delete it, making the package upgradation fails. While tsc-dyn-get already has warnings about that, package upgradation failure often confuses Emacs. Make it loads wrong packages or worse, make the package-quick-refresh fails due to trying to read obsoleted empty autoload file (which has been deleted as part of package upgrade).

A sensible fix on Windows is to move the load dll into temp folder, marks it as delete on next reboot, but that will require fix in package.el, and seems to be overcomplicating thing.

On tsc, if we can make the tsc-dyn path to be customizable, it would also fixes the problem of package upgradation. And provides user an option to store binaries in cache path, make it possible to no need to download the binaries again in next package upgrade.