Content-Length: 284326 | pFad | https://github.com/cbarrete/tree-sitter-ledger

CB GitHub - cbarrete/tree-sitter-ledger: Ledger grammar for tree-sitter
Skip to content

cbarrete/tree-sitter-ledger

Repository files navigation

tree-sitter-ledger

A ledger parser built with tree-sitter.

Contributing

Only the Nix toolchain is supported to get the tree-sitter binary. You can add it to your path by running nix develop. The NPM toolchain is best-effort only and not actively maintained.

Regardless, I personally regenerate the code after every merged PR to prevent the risk of a contributor lacing malicious code into the generated output.

Note for nvim-treesitter users

negative_quantity is exposed by tree-sitter-ledger, but not treated specially in nvim-treesitter. You can add special highlighting for it (e.g. to highlight negative quantities in red) by runnning :TSEditQueryUserAfter and filling in something like:

;; extends
((negative_quantity) @some_capture)

where @some_capture should map to some highlight group in your colorscheme.

Note for integration maintainers

I also maintain the ledger queries in nvim-treesitter. Consider consulting them for hints about what tree-sitter-ledger exposes.

About

Ledger grammar for tree-sitter

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published








ApplySandwichStrip

pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

Fetched URL: https://github.com/cbarrete/tree-sitter-ledger

Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy