fix: use /c instead of -c on windows in postinstall hook#6397
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull Request Overview
This PR fixes shell command execution on Windows by replacing hardcoded "-c" flags with a platform-specific constant. The change ensures proper shell command execution across different operating systems by using "/c" on Windows and "-c" on Unix systems.
- Introduces platform-specific shell command flag constants
- Refactors hardcoded shell command flags to use the new constants
- Consolidates shell command flag logic in a central location
Reviewed Changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| src/env.rs | Defines platform-specific shell command flag constants |
| src/cli/exec.rs | Updates command parsing to use the new shell command flag constant |
| src/backend/mod.rs | Replaces hardcoded "-c" with the platform-specific constant |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
Owner
|
bugbot run |
jdx
added a commit
that referenced
this pull request
Sep 25, 2025
### 📦 Registry - replace amplify-cli github backend with ubi by @eggplants in [#6396](#6396) ### 🚀 Features - **(template)** add read_file() function by @jdx in [#6400](#6400) ### 🐛 Bug Fixes - **(aqua)** support github_artifact_attestations.enabled by @risu729 in [#6372](#6372) - use /c instead of -c on windows in postinstall hook by @risu729 in [#6397](#6397) ### 🧪 Testing - **(test-tool)** uninstall all versions and clear cache before installation by @jdx in [#6393](#6393) ### New Contributors - @eggplants made their first contribution in [#6396](#6396) Co-authored-by: mise-en-dev <release@mise.jdx.dev>
netbsd-srcmastr
pushed a commit
to NetBSD/pkgsrc
that referenced
this pull request
Sep 25, 2025
## [2025.9.18](https://github.com/jdx/mise/compare/v2025.9.17..v2025.9.18) - 2025-09-24 ### 📦 Registry - replace amplify-cli github backend with ubi by @eggplants in [#6396](jdx/mise#6396) ### 🚀 Features - **(template)** add read_file() function by @jdx in [#6400](jdx/mise#6400) ### 🐛 Bug Fixes - **(aqua)** support github_artifact_attestations.enabled by @risu729 in [#6372](jdx/mise#6372) - use /c instead of -c on windows in postinstall hook by @risu729 in [#6397](jdx/mise#6397) ### 🧪 Testing - **(test-tool)** uninstall all versions and clear cache before installation by @jdx in [#6393](jdx/mise#6393) ### New Contributors - @eggplants made their first contribution in [#6396](jdx/mise#6396) ## [2025.9.17](https://github.com/jdx/mise/compare/v2025.9.16..v2025.9.17) - 2025-09-24 ### 🚀 Features - **(java)** add support for Liberica NIK releases by @roele in [#6382](jdx/mise#6382) ### 🐛 Bug Fixes - **(toolset)** handle underflow in version_sub function by @koh-sh in [#6389](jdx/mise#6389) ### 📚 Documentation - document MISE_ENV behavior for global/system configs by @jdx in [#6385](jdx/mise#6385) ### New Contributors - @jc00ke made their first contribution in [#6386](jdx/mise#6386) - @koh-sh made their first contribution in [#6389](jdx/mise#6389)
riastradh
pushed a commit
to riastradh/pkgsrc-test20250901
that referenced
this pull request
Feb 8, 2026
## [2025.9.18](https://github.com/jdx/mise/compare/v2025.9.17..v2025.9.18) - 2025-09-24 ### 📦 Registry - replace amplify-cli github backend with ubi by @eggplants in [#6396](jdx/mise#6396) ### 🚀 Features - **(template)** add read_file() function by @jdx in [#6400](jdx/mise#6400) ### 🐛 Bug Fixes - **(aqua)** support github_artifact_attestations.enabled by @risu729 in [#6372](jdx/mise#6372) - use /c instead of -c on windows in postinstall hook by @risu729 in [#6397](jdx/mise#6397) ### 🧪 Testing - **(test-tool)** uninstall all versions and clear cache before installation by @jdx in [#6393](jdx/mise#6393) ### New Contributors - @eggplants made their first contribution in [#6396](jdx/mise#6396) ## [2025.9.17](https://github.com/jdx/mise/compare/v2025.9.16..v2025.9.17) - 2025-09-24 ### 🚀 Features - **(java)** add support for Liberica NIK releases by @roele in [#6382](jdx/mise#6382) ### 🐛 Bug Fixes - **(toolset)** handle underflow in version_sub function by @koh-sh in [#6389](jdx/mise#6389) ### 📚 Documentation - document MISE_ENV behavior for global/system configs by @jdx in [#6385](jdx/mise#6385) ### New Contributors - @jc00ke made their first contribution in [#6386](jdx/mise#6386) - @koh-sh made their first contribution in [#6389](jdx/mise#6389)
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.
Fixes #6388