fix: resolve vp --version showing v0.0.0 on Windows#767
Merged
Conversation
✅ Deploy Preview for viteplus-staging ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
branchseer
approved these changes
Mar 10, 2026
Add `defaults: run: shell: bash` to the `build-rust` job in the release workflow so that version placeholder replacement uses bash instead of PowerShell on Windows runners, fixing quoting issues with embedded double quotes. Add a verification step to catch silent replacement failures early. Also enable the replace-file-content snap test on win32.
9030ad3 to
4bc1550
Compare
Member
Author
Merge activity |
Member
Author
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.


Summary
shell: bashto the "Set binding version" and "Verify version replacement" steps in the release workflow, fixing PowerShell quoting issues that causedreplace-file-contentto silently fail on Windows runnersreplace-file-contentsnap test on win32 (removeignoredPlatforms)Root Cause
The
build-rustjob inrelease.ymlruns onwindows-latestwithout specifying a shell, so GitHub Actions defaults to PowerShell. PowerShell mangles embedded double quotes in single-quoted arguments like'version = "0.0.0"', causing the search string to never match. The replacement silently fails, and the binary compiles withversion = "0.0.0"still inCargo.toml.Verified by temporarily disabling the fix and confirming the CI fails with
version = "0.0.0"still present.Test plan
shell: bashon the version replacement steps🤖 Generated with Claude Code