Replace git submodule with package dependency for tree-sitter integration#23
Conversation
|
Thank you so much for this! I've been thinking about this change for a very long time myself. It's a shame this conflict is even a thing. I'd love to find a way to share more significant infrastructure with Runestone aside from just the runtime. But, until that day comes, I think this is a good tradeoff for the sake of compatibility. |
|
Ah looks like perhaps some tests still need to be updated? |
Fixed |
|
Some of the tests are still failing. Let me have a look. |
…h the tree-sitter library.
|
The tree-sitter package has a higher-than-required watchOS version. Lowering that will be a pain, so let's just raise it here. |
From the documentation if we don't specify a platform requirement, the oldest deployment targets will be selected by default. So we can just remove it to keep consistency with the tree-sitter package. |
|
Ah. The documentation is right! Leaving it out is fine if you don't actually rely on the implicit value. If it does matter, clients that change to a lower swift version will implicitly lower yours and cause breakage. In general, I've found it to be a rare, but annoying compatibility issue when left blank. |
|
But, I also don't want to make too much work for you. I'lll deal with that if it comes up! |
… "0.25.0" (#78) This PR contains the following updates: | Package | Update | Change | |---|---|---| | [tree-sitter/swift-tree-sitter](https://github.com/tree-sitter/swift-tree-sitter) | minor | `from: "0.8.0"` -> `from: "0.25.0"` | --- ### Release Notes <details> <summary>tree-sitter/swift-tree-sitter (tree-sitter/swift-tree-sitter)</summary> ### [`v0.25.0`](tree-sitter/swift-tree-sitter@0.9.0...0.25.0) [Compare Source](tree-sitter/swift-tree-sitter@0.9.0...0.25.0) ### [`v0.9.0`](https://github.com/tree-sitter/swift-tree-sitter/releases/tag/0.9.0) [Compare Source](tree-sitter/swift-tree-sitter@0.8.0...0.9.0) #### What's Changed - fix ios cannot load queries issue by [@​ElvisWong213](https://github.com/ElvisWong213) in [tree-sitter/swift-tree-sitter#22](tree-sitter/swift-tree-sitter#22) - Replace git submodule with package dependency for tree-sitter integration by [@​yeatse](https://github.com/yeatse) in [tree-sitter/swift-tree-sitter#23](tree-sitter/swift-tree-sitter#23) - Hotfix alloc crash, when no read data avail. by [@​furby-tm](https://github.com/furby-tm) in [tree-sitter/swift-tree-sitter#24](tree-sitter/swift-tree-sitter#24) - Fix README formatting by [@​nakajima](https://github.com/nakajima) in [tree-sitter/swift-tree-sitter#27](tree-sitter/swift-tree-sitter#27) - export tree sitter's id field by [@​lijunsong](https://github.com/lijunsong) in [tree-sitter/swift-tree-sitter#28](tree-sitter/swift-tree-sitter#28) - Add `reset` Method On Parser by [@​thecoolwinter](https://github.com/thecoolwinter) in [tree-sitter/swift-tree-sitter#30](tree-sitter/swift-tree-sitter#30) - Deprecate `ResolvingQueryCursor. injections()` - Lots of documentation additions - `includedRanges` API for both `Tree` and `MutableTree` - Many bug fixes for `LanguageLayer` - Sublayer resolution is now opt-in - Some concurrency-related fixes - Parser bundle queries are now found on iOS - Removed the need for escaping closures in parsing functions - Attempting to use a language layer query that is unsupported now throws - Use tree-sitter 0.23.0 #### New Contributors - [@​ElvisWong213](https://github.com/ElvisWong213) made their first contribution in [tree-sitter/swift-tree-sitter#22](tree-sitter/swift-tree-sitter#22) - [@​yeatse](https://github.com/yeatse) made their first contribution in [tree-sitter/swift-tree-sitter#23](tree-sitter/swift-tree-sitter#23) - [@​furby-tm](https://github.com/furby-tm) made their first contribution in [tree-sitter/swift-tree-sitter#24](tree-sitter/swift-tree-sitter#24) - [@​nakajima](https://github.com/nakajima) made their first contribution in [tree-sitter/swift-tree-sitter#27](tree-sitter/swift-tree-sitter#27) - [@​lijunsong](https://github.com/lijunsong) made their first contribution in [tree-sitter/swift-tree-sitter#28](tree-sitter/swift-tree-sitter#28) - [@​thecoolwinter](https://github.com/thecoolwinter) made their first contribution in [tree-sitter/swift-tree-sitter#30](tree-sitter/swift-tree-sitter#30) **Full Changelog**: <tree-sitter/swift-tree-sitter@0.8.0...0.9.0> </details> --- ### Configuration 📅 **Schedule**: Branch creation - Between 12:00 AM and 03:59 AM ( * 0-3 * * * ) in timezone Pacific/Auckland, Automerge - Between 12:00 AM and 03:59 AM ( * 0-3 * * * ) in timezone Pacific/Auckland. 🚦 **Automerge**: Disabled because a matching PR was automerged previously. ♻ **Rebasing**: Whenever PR is behind base branch, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [Renovate Bot](https://github.com/renovatebot/renovate). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiI0MS4xNy4wIiwidXBkYXRlZEluVmVyIjoiNDEuODIuNiIsInRhcmdldEJyYW5jaCI6Im1haW4iLCJsYWJlbHMiOlsicmVub3ZhdGUiXX0=--> Reviewed-on: https://harton.dev/outrun/outrun/pulls/78 Co-authored-by: Renovate Bot <bot@harton.nz> Co-committed-by: Renovate Bot <bot@harton.nz>
Some of the dependencies of my project (like Runestone) rely on the tree-sitter project directly, which leads to conflicts due to duplicated symbols. This PR tries to fix this by replacing the tree-sitter git submodule with a Swift package dependency.
Note that the
tree-sitter-swiftsubmodule remains unchanged in this PR because it is currently used only for testing purposes, and altering it would introduce unnecessary dependencies.