Docs: rbs and toml#92
Open
pboling wants to merge 2 commits intostackmystack:masterfrom
Open
Conversation
There was a problem hiding this comment.
Pull request overview
This PR expands the documented/tested from override support by adding real-world examples for Tree-sitter grammars that live outside the default tree-sitter/tree-sitter-<lang> GitHub org/repo naming pattern (TOML and RBS), pinned to known versions.
Changes:
- Document
fromoverrides fortoml(tree-sitter-grammars) andrbs(joker1007) in the README example config. - Mirror those same examples in the crate-level rustdoc configuration snippet (
src/lib.rs). - Extend the CLI build integration tests to cover pinned
fromoverrides fortomlandrbs.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| tests/cmd/build.rs | Adds pinned build test cases and config fixtures for toml and rbs using from overrides. |
| src/lib.rs | Updates rustdoc TOML config example to include toml and rbs from overrides. |
| README.md | Updates user-facing config example to include toml and rbs from overrides. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Owner
|
Thanks for the PR. I would only ask to follow the commit style of the repo and avoid emojis. Once that's done and the test suite passes, I'll merge. |
The toml tree-sitter grammar is maintained under the tree-sitter-grammars org, not the default tree-sitter org. Add toml as a documented example of the `from` override in README, rustdoc, and test fixtures. Pinned at v0.7.0 (64b56832c2cffe41758f28e05c756a3a98d16f41). Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
473225d to
5afbba6
Compare
- Add tree-sitter-rbs v0.2.2 with from override to README, rustdoc, and tests - rbs-merge can use tree-sitter-rbs as a backend for RBS type signature parsing Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
5afbba6 to
808c0ef
Compare
Author
|
@stackmystack fixed! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
The toml tree-sitter grammar is maintained under the tree-sitter-grammars org, not the default tree-sitter org - pinned at v0.7.0.
The rbs tree-sitter grammar is maintained by @joker1007, not the default tree-sitter org - pinned at v0.2.2.
Add toml and rbs as a documented examples of the
fromoverride in README, rustdoc, and test fixtures.Motivation and Context
Just adds documentation and test support for toml and rbs grammars, since they are becoming more widely used in Ruby-land. ;)
I have also integrated tsdl into my ts-grammar-action, so it now downloads released version of tsdl, and uses it to install grammars! I am now beginning use that GitHub Action in at least one workflow in all of my gems, as I begin validating their coherence with my gem template, and they will use tree sitter grammars to accomplish much of that work via my ast-merge gem & friends. in other words - all of my gems will depend on this in GHA soon.
How Has This Been Tested?
Both grammars built and verified successfully:
• toml v0.7.0 → libtree-sitter-toml.so (37K) — exports tree_sitter_toml + external scanner symbols
• rbs v0.2.2 → libtree-sitter-rbs.so (129K) — exports tree_sitter_rbs
Total build time: 2.3s (including tree-sitter-cli download). The from overrides for both non-standard repos (tree-sitter-grammars/tree-sitter-toml and joker1007/tree-sitter-rbs) work correctly.
Types of Changes
Checklist: