tree-sitter-strudel

Crates.iotree-sitter-strudel
lib.rstree-sitter-strudel
version1.1.8
created_at2025-07-28 18:48:36.532288+00
updated_at2025-08-01 12:40:49.003944+00
descriptionParser for Strudel, a Tidal Cycles base live coding tool
homepage
repositoryhttps://github.com/pedrozappa/tree-sitter-strdl
max_upload_size
id1771476
size224,455
Zedro (PedroZappa)

documentation

README

tree-sitter-strdl

Tree-sitter parser for Strudel, a Tidal Cycles based live coding tool.


Usage

To install the parser in Neovim:

  • Create a file strudel-integration.lua in your ~/.config/nvim/lua/ directory:
---@class ParserConfig
local parser_config = require("nvim-treesitter.parsers").get_parser_configs()
parser_config.strudel = {
  install_info = {
    -- url = "https://github.com/pedrozappa/tree-sitter-strdl", -- local path or git repo
    url = "~/tree-sitter-strdl/", -- local path to this repo
    files = { "src/parser.c" }, -- note that some parsers also require src/scanner.c or src/scanner.cc
    -- optional entries:
    branch = "main", -- default branch in case of git repo if different from master
    generate_requires_npm = false, -- if stand-alone parser without npm dependencies
    requires_generate_from_grammar = false, -- if folder contains pre-generated src/parser.c
  },
  filetype = "strdl", -- if filetype does not match the parser name
}

vim.api.nvim_create_autocmd("BufRead", {
  pattern = { "*.strdl", "*.strudel" },
  callback = function()
    vim.bo.filetype = "strdl"
  end,
})
  • On your ~/.config/nvim/init.lua:
require("strudel-integration")

Run the following to install the parsers schemas:

npm run local_install

Docs

Learning Resources

Commit count: 0

cargo fmt