2 stable releases
new 3.6.0 | Jun 13, 2025 |
---|---|
3.5.1 | Jun 13, 2025 |
#2900 in Parser implementations
92 downloads per month
480KB
17K
SLoC
This crate provides fish language support for the tree-sitter parsing library.
Typically, you will use the language function to add this language to a tree-sitter Parser, and then use the parser to parse some code:
let code = "";
let mut parser = tree_sitter::Parser::new();
parser.set_language(tree_sitter_fish::language()).expect("Error loading fish grammar");
let tree = parser.parse(code, None).unwrap();
tree-sitter-fish
Fish grammar for tree-sitter.
Development
Install the dependencies:
npm install
Run the tests:
npm run test
Run the build and tests in watch mode:
npm run test:watch
Test parser against fish-shell /share
fish files:
npm run test:examples
References
Dependencies
~2.8–4.5MB
~80K SLoC