21 Commits

Author SHA1 Message Date
Christian Clason
0ac55b85c6 refactor(lua): replace vim.opt with vim.o 2026-01-27 11:57:04 +01:00
Christian Clason
fd2880e8bc feat(install): remove node requirement
* supported parsers _must_ commit at least `grammar.json`
* set `TREE_SITTER_JS_RUNTIME=native` when generating parser to use
  built-in quickjs instead of node (requires tree-sitter 0.26)
2025-10-30 08:36:00 +01:00
Christian Clason
53d7118483 refactor(lua): fix some luals warnings 2025-05-12 18:43:40 +02:00
Christian Clason
bdc2e01958 feat(install)!: always generate from json if possible 2025-05-12 18:43:40 +02:00
Christian Clason
214cfcf851 feat!: use tree-sitter build 2025-05-12 18:43:40 +02:00
Christian Clason
c17de56890 feat!: track parser revision in Lua
Problem: Tracking parser revision in lockfile and allowing override
through the parsers module complicates the code. In addition, only
revision changes are handled robustly, not changes to other installation
info.

Solution: Track parser revision in the parsers module directly. Reload
parser table on every install or update call. Support modifying parser
table in a `User TSUpdate` autocommand.
2025-05-12 18:43:40 +02:00
Christian Clason
5a38df5627 feat(install)!: generate from json instead of requiring node
Problem: Many parsers require node/npm to evaluate the `grammar.js`
before being able to generate a parser from it.

Solution: Generate from `grammar.json` instead, which is fully resolved.
Drops `node` and `npm` as (optional) requirements for nvim-treesitter.

Note that this requires parsers to commit the generated json iff the
grammar requires evaluation (which is currently the case for all tracked
languages).
2025-05-12 18:43:40 +02:00
Christian Clason
37957d6bcf refactor: use vim.uv 2025-05-12 18:43:40 +02:00
Christian Clason
cd2c826972 fix: install dependencies 2025-05-12 18:43:40 +02:00
Christian Clason
9c0a99819c ci: remove update-lockfile shell script 2025-05-12 18:43:40 +02:00
Lewis Russell
cde679e435 refactor: rewrite installation using jobs and async
Replace sync variants with callback support
2025-05-12 18:43:40 +02:00
Christian Clason
5817ff01b5 feat(locals)!: refactor locals.lua into standalone
Co-authored-by: TheLeoP <eugenio2305@hotmail.com>
2025-05-12 18:43:40 +02:00
Christian Clason
692b051b09 feat!: drop modules, general refactor and cleanup 2025-05-12 18:43:40 +02:00
ObserverOfTime
f8bc6c69d7 ci: add shebangs to scripts 2023-08-18 11:09:57 +03:00
Amaan Qureshi
853b1ab39a style: fill in missing code docs wherever applicable 2023-02-24 01:08:23 -08:00
ObserverOfTime
370546d283 ci(readme): add experimental annotation
even when the grammar is unmaintained
2022-11-20 12:24:55 +01:00
Cezary Drożak
e87ed0fdaa feat: add "experimental" key to parsers
feat(ci): mark parsers as experimental in README
2021-10-07 22:43:09 +02:00
Santos Gallegos
be8f656087 Use stylua for autoformat code (#1480) 2021-07-04 21:12:17 +00:00
Stephan Seitz
ffe7d96dfd feat(CI): auto-update README.md 2020-08-31 18:53:24 +02:00
Stephan Seitz
47b45ff883 feat(CI): print text what went wrong when README CI fails 2020-08-25 15:22:15 +02:00
Stephan Seitz
7c9ffe9e19 Fix #292: Add parser links to README.md 2020-08-25 14:58:28 +02:00