Add Zig highlighting - #925
Conversation
|
@microsoft-github-policy-service agree |
There was a problem hiding this comment.
I don't really know how to do PRs and never done them so I decided that I will do that.
I see. It would be trivial to fix for me, but it's better for you to learn the ropes!
If you check the other PR you'll find that the files have to go somewhere particular, not just in some random directory. So put that AI of yours away, install rustup and understand how this project works and can be tested locally. It will be difficult, but worthwhile!
|
Oh I actually already compiled and tested it locally but i think i messed up with git... |
| } else if /\.[a-zA-Z_]\w*/ { | ||
| yield variable; // Catches ZON field keys like .name, .version |
There was a problem hiding this comment.
It may be best to not highlight terms that are ambiguous. This one is, isn't it?
Lakshay Chauhan (nos1dot618)
left a comment
There was a problem hiding this comment.
edit/crates/lsh/definitions/markdown.lsh
Lines 43 to 52 in 826b4c0
We should also add zig highlighting mode inside markdown's code block, just like this snippet for javascript.
|
Zig should not go into the markdown definition. That's reserved for when we have dynamic language lookups. |
This PR adds initial LSH syntax highlighting support for Zig including .zon files (Zig Object Notation)
It also includes highlighting test file.
Scope
This is a lightweight LSH-only change with no new dependencies.
The changes are limited to syntax definitions and highlighting fixtures:
Validation
cargo test -qNotes
You may notice that this PR is heavily inspired by and modelled after #791 and #796. I don't really know how to do PRs and never done them so I decided that I will do that.