Open jcs090218 opened 3 years ago
Windows seems to disallow deleting loaded dll files.
I'm not familiar enough with Windows to fix this, or to suggest workarounds.
I think you can customize tree-sitter-langs-grammar-dir
for that. So the langs dll is stored outside of package and will not be delete when upgrading.
(use-package tree-sitter-langs
:ensure t
:defer t
:custom
(tree-sitter-langs-grammar-dir (expand-file-name ".cache/tree-sitter-langs/" user-emacs-directory)))
In Windows, loaded dll cannot be deleted online but can be moved and marked to delete next time PC reboot.
Perhaps package.el
should use that, i.e, move loaded dll file to $TEMP
and mark it as delete on reboot, then we can cleanly upgrade package on Windows without worry about file deletion error.
If I have
tree-sitter
running with dynamic link file (dll) then I am not able to upgradetree-sitter-langs
package.Steps of reproduce
tree-sitter
support (ensure there is process running with dll file)package-list-packages
, and try to remove packagetree-sitter-langs
Then you should get an error with process running, not able to delete package, etc.
Environments