Closed devanlooches closed 1 year ago
Oh, the instructions in the README appear to be incomplete.
It appears you will have to copy the contents of the queries
folder from this repository into ~/.config/helix/runtime/queries/typst/
.
Alternatively, clone the repository somewhere and then symlink the queries
folder:
$ mkdir -p ~/.config/helix/runtime/queries/
$ ln -s ~/development/tree-sitter-typst/queries/ ~/.config/helix/runtime/queries/typst
Replace ~/development/tree-sitter-typst
with the absolute path to your clone.
Hello, thank you for the response. I tried symlinking the clone to the folder and this did not seem to do anything. Any ideas?
Try running
$ helix --grammar fetch && helix --grammar build
Check if that works.
If not, then does cat ~/.config/helix/runtime/queries/typst/highlights.scm
output anything?
Running your first command returned: Error: data did not match any variant of untagged enum GrammarSource in "grammar.source"
Running the second command did print:
(block_comment) @comment.block
(markup) @markup
(escape) @string.escape
(shorthand) @punctuation
(smart_quote) @punctuation
(raw) @markup.raw.inline
(link) @markup.link.url
(label) @markup.label
(strong) @markup.bold
(emph) @markup.italic
(heading
(heading_start) @markup.heading.marker
) @markup.heading
I retried with the newest update and it seems to work now although it only highlights strings a different color. I think that is a problem with my theme though.
Hi I'm probably doing something wrong but I followed the instructions in the README and there does not seem to be any syntax highlighting happening.
Thanks in advance for the help!