From 8dd21ff082f549b38f66be3edcf63c3cf74deaa4 Mon Sep 17 00:00:00 2001 From: Marc Jakobi Date: Wed, 13 Mar 2024 20:14:37 +0100 Subject: [PATCH] feat: add tree-sitter parsers for linux - only ones that don't need their sources generated for now --- .github/workflows/build-linux-x86_64.yml | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/.github/workflows/build-linux-x86_64.yml b/.github/workflows/build-linux-x86_64.yml index 316d2168d..9a5ab24eb 100644 --- a/.github/workflows/build-linux-x86_64.yml +++ b/.github/workflows/build-linux-x86_64.yml @@ -45,6 +45,25 @@ jobs: run: | luarocks --verbose --local --lua-version=5.1 install fzy luarocks --verbose pack fzy + - name: Install `luarocks-build-treesitter-parser` Package + run: | + luarocks --verbose --local --lua-version=5.1 install luarocks-build-treesitter-parser + - name: Get tree-sitter-parsers.json + uses: actions/checkout@v4 + with: + repository: nvim-neorocks/nurr + sparse-checkout: | + tree-sitter-parsers.json + path: nurr + - name: Install tree-sitter parsers + run: | + # Filter out parsers that need their sources generated + # We might want to consider adding those too + langs=$(jq -r '.parsers[] | select((.install_info.requires_generate_from_grammar // false) == false) | .lang' nurr/tree-sitter-parsers.json) + for lang in $langs; do + luarocks --local --lua-version=5.1 install "tree-sitter-$lang" \ + && luarocks pack "tree-sitter-$lang" + done - name: Regenerate Manifests and HTML run: luarocks-admin make-manifest --lua-version=5.1 . - name: commit-linux-x86_64