This is a fork of
the-mikedavis/tree-sitter-diff
that basically just adds a > in front of every line.
I did this because I wanted to try out the
mailing-list-style-code-review-tool-for-GitHub, prr,
but wanted to have syntax highlighting in
Helix.
Update your languages.toml with the following:
[[language]]
name = "prr"
scope = "source.prr"
roots = []
file-types = ["prr"]
injection-regex = "prr"
[[grammar]]
name = "prr"
source = { git = "https://github.com/bcspragu/tree-sitter-diff", rev = "3390ef2dce6c749900a9dca72671b06c83d2bc59" }And then run hx --grammar fetch && hx --grammar build. I had to do a bunch of
manual chown-ing because the
Arch AUR helix-git package puts
everything in /usr/lib/helix, which is owned by root.
I swear it works, here's a diff of
a random Helix PR I loaded
with prr get helix-editor/helix/4079:
