Skip to content

make ts.require call compatible with tree-sitter-teal rock#57

Merged
euclidianAce merged 1 commit intomainfrom
fix-ts-require
Mar 10, 2025
Merged

make ts.require call compatible with tree-sitter-teal rock#57
euclidianAce merged 1 commit intomainfrom
fix-ts-require

Conversation

@hishamhm
Copy link
Member

@hishamhm hishamhm commented Mar 8, 2025

If one builds the dependencies with LuaRocks doing

luarocks install ltreesitter
luarocks install tree-sitter-teal

The resulting parser gets installed in lib/lua/5.x/parser/teal.so.

Perhaps instead of this change, which includes a Unixy / path and probably breaks someone else's setup, ltreesitter should be changed instead, to make it automatically search within a parser directory when doing its Lua package.cpath search.

If one builds the dependencies with LuaRocks doing

```
luarocks install ltreesitter
luarocks install tree-sitter-teal
```

The resulting parser gets installed in `lib/lua/5.x/parser/teal.so`.

Perhaps instead of this change, which includes a Unixy `/` path and
probably breaks someone else's setup, ltreesitter should be changed
instead, to allow automatically searching within a `parser` directory
when doing its Lua package.cpath search.
@euclidianAce
Copy link
Member

Huh, didn't know tree-sitter-teal got published to luarocks (looks like the neovim people have some automation to do that). Yeah, this probably belongs in ltreesitter.

@euclidianAce euclidianAce merged commit 00e6088 into main Mar 10, 2025
5 checks passed
@euclidianAce
Copy link
Member

I'll merge this anyway since it's what works with the luarocks installed verison

@hishamhm
Copy link
Member Author

By the way, your lint script that uses tree-sitter-teal is really cool and I think it would be great if it effectively became cyan clippy!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants