typst-lsp
typst-lsp copied to clipboard
Port some changes from the linguist pull request?
I saw https://github.com/michidk/typst-grammar/commit/4221511bb563b71e66c52cc529fbebe57bdb53d9 from https://github.com/github-linguist/linguist/pull/6379 which attempts to add Typst to GitHub linguist, and they author claimed that
So the original grammar from https://github.com/nvarner/typst-lsp had the following errors: ... I now made a fork (https://github.com/michidk/typst-grammar) that has the required structure and fixes the issues. The script runs and completes now without errors:
Maybe we can port that patch to this repo (should be very easy, just apply the diff)
Keep in mind that my fork is probably very outdated by now. But I agree, it would be great if we could have an LSP definition compatible with GitHub's linguist. Then I could delete my repository and adjust my PR to use this one.
Btw the list of incompatibilities can be found here: https://github.com/github-linguist/linguist/pull/6379#issuecomment-1512862673
The TextMate grammar in this repo is unused and unmaintained. We switched to semantic token highlighting because it's based on the Typst parser, so we don't need to keep up with changes to the language's grammar. I'd be willing to patch in the changes, but I can't commit to keeping it up to date.