treesit-auto icon indicating copy to clipboard operation
treesit-auto copied to clipboard

The new version opens the CPP file and cannot find C (the right that should be found C ++)

Open ipyffor opened this issue 1 year ago • 1 comments

Steps to Reproduce:

  1. Open cpp file, install cpp treesit
  2. restart emacs
  3. Open cpp file, tip: Warning (treesit): Cannot activate tree-sitter, because language grammar for c is unavailable

Temporarily can be solved by installing the Treesit library of C:

Open c file to install c treesit lib

ipyffor avatar Mar 02 '24 04:03 ipyffor

In our recipe for C++, we don't have a :requires keyword in there:

https://github.com/renzmann/treesit-auto/blob/1b63bc5e50def3c14ab69e53ed6e7f65a7482016/treesit-auto.el#L130-L135

For instance, we say that gomod requires go

https://github.com/renzmann/treesit-auto/blob/1b63bc5e50def3c14ab69e53ed6e7f65a7482016/treesit-auto.el#L173-L179

If you open a PR that adds this :requries keyword and test that it works for your use case, I'm happy to take it

renzmann avatar Apr 20 '24 14:04 renzmann