Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add tree-sitter-markdown grammar #215

Closed
archseer opened this issue Jun 10, 2021 · 3 comments
Closed

Add tree-sitter-markdown grammar #215

archseer opened this issue Jun 10, 2021 · 3 comments
Labels
A-tree-sitter Area: Tree-sitter C-enhancement Category: Improvements

Comments

@archseer
Copy link
Member

https://github.com/ikatyang/tree-sitter-markdown

@archseer archseer added A-tree-sitter Area: Tree-sitter E-easy Call for participation: Experience needed to fix: Easy / not much labels Jun 10, 2021
@archseer archseer removed the E-easy Call for participation: Experience needed to fix: Easy / not much label Aug 21, 2021
@kirawi kirawi added the C-enhancement Category: Improvements label Sep 27, 2021
@lightningx10
Copy link

What's going on here? It seems like no one has managed to get this working.

I've cloned in the tree-sitter-markdown in the helix-syntax/languages/ directory, and added the following entry to languages.toml

[[language]]
name = "markdown"
scope = "source.md"
file-types = ["md"]
roots = []

But helix still cannot render the syntax highlighting, which is strange considering it's meant to be automatic at runtime. I'm not sure what to do. Is there something that I'm missing?

@lightningx10
Copy link

I've seemingly been able to get it to compile, I also added some more files into runtime/queries/markdown/* files of the previous attempt at a patch. It all worked and compiled, but if there's any mention of code_block anywhere in there then the program will fail at runtime. Not sure what causes this. After removing code_block from there, helix will be able to load markdown, but no syntax highlighting will be drawn making me think that I'm missing something still. Maybe there's more to be done in the runtime/queries section?

@archseer
Copy link
Member Author

The problem is that the grammar is unstable and can panic: nvim-treesitter/nvim-treesitter#872 (comment)

Until that's resolved we can't really proceed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-tree-sitter Area: Tree-sitter C-enhancement Category: Improvements
Projects
None yet
Development

No branches or pull requests

3 participants