dimitarvp
Can the Elixir team fix the tree-sitter-elixir Rust crate's repository link?
To @jonatanklosko and @the-mikedavis:
I see that there is a Rust crate at crates.io: Rust Package Registry but it is pointing at https://github.com/tree-sitter/tree-sitter-elixir – and that no longer exists.
Can this be fixed to correctly point to GitHub - elixir-lang/tree-sitter-elixir: Elixir grammar for tree-sitter, please? Assuming they are even the same which they might not be.
I am looking into making a PR to GitHub - ast-grep/ast-grep: ⚡A CLI tool for code structural search, lint and rewriting. Written in Rust so Elixir can be included in the semantic / structural code search that this tool provides.
I am asking for this because the project’s Cargo.toml needs a valid crate to point at a language grammar before the small boilerplate required to add a language can work: ast-grep/crates/language/Cargo.toml at 782b175dacaf161cd567538f01929c5e78074e9f · ast-grep/ast-grep · GitHub
/CC @josevalim
Most Liked
dimitarvp
ast-grep version 0.14.3 has been released and is now supporting Elixir.
Example usage:
# or "ex" for a shorthand name for Elixir.
$ sg -l elixir -p '$A != nil'
dimitarvp
My PR has been merged.
We’ll have Elixir support in ast-grep come next release (so a matter of days).
dimitarvp
If anyone is interested, I have also made a PR to have their online playground support Elixir as well: Add Elixir support by dimitarvp · Pull Request #323 · ast-grep/ast-grep.github.io · GitHub.
And it’s merged.
Meaning that you can visit Playground | ast-grep and try out stuff without installing the tool.
shanesveller
Notably you cannot publish a release to crates.io if it contains any git dependencies, so many packages that are actually CLIs or other end-user applications may forbid introducing such changes. On the projects’ side the stance is mainly motivated to protect the ability to cargo install the package by name.
I knew this from past friction; and Specifying Dependencies - The Cargo Book mentions that near the bottom of that section, but I couldn’t trivially find a page directly on crate.io to cite.







