Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support cmd.exe and PowerShell #1625

Merged
merged 3 commits into from Sep 30, 2022
Merged

Support cmd.exe and PowerShell #1625

merged 3 commits into from Sep 30, 2022

Conversation

lfdebrux
Copy link
Member

@lfdebrux lfdebrux commented Sep 27, 2022

Stop showing users an error if they run the kit on Windows without using Bash.

Bash is no longer a requirement of running our tests or the kit, so this PR changes our tests to use the default shells on Windows rather than forcing the use of Bash.

We also change the .npmrc file the user receives so that it does not try and use bash for npm run on Windows.

@lfdebrux lfdebrux force-pushed the ldeb-support-powershell branch 3 times, most recently from 8bfa24b to f939afe Compare September 27, 2022 15:33
@lfdebrux lfdebrux changed the title Support PowerShell Support PowerShell and CMD.exe Sep 28, 2022
@lfdebrux lfdebrux changed the title Support PowerShell and CMD.exe Support CMD.exe and PowerShell Sep 28, 2022
@lfdebrux lfdebrux changed the title Support CMD.exe and PowerShell Support cmd.exe and PowerShell Sep 28, 2022
@lfdebrux lfdebrux force-pushed the ldeb-support-powershell branch 3 times, most recently from 09f2636 to 8982b0a Compare September 29, 2022 12:29
@lfdebrux lfdebrux marked this pull request as ready for review September 29, 2022 12:29
@lfdebrux lfdebrux requested a review from a team September 29, 2022 12:29
@lfdebrux
Copy link
Member Author

As well as testing this in CI, I tested this locally with a Windows laptop. After verifying I could reproduce the error reported in #1578 without these changes, I verified that the kit worked fine with the code in this PR.

@lfdebrux lfdebrux force-pushed the ldeb-support-powershell branch 3 times, most recently from ba7be0f to ff829df Compare September 29, 2022 18:29
Previously we forced GitHub Actions and npm to use bash as the shell on
all operating systems, npm defaults to using cmd.exe on Windows [[1]],
GitHub Actions defaults to using PowerShell on Windows [[2]]. This
commit removes the overrides, and also fixes up the npm package scripts
syntax to support cmd.exe.

[1]: https://docs.npmjs.com/cli/v8/using-npm/config#script-shell
[2]: https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsshell
@lfdebrux lfdebrux force-pushed the ldeb-support-powershell branch 2 times, most recently from 26370cc to 32450ce Compare September 29, 2022 19:29
package.json Show resolved Hide resolved
@lfdebrux lfdebrux merged commit 1c2e0fc into v13 Sep 30, 2022
@lfdebrux lfdebrux deleted the ldeb-support-powershell branch September 30, 2022 09:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Running the kit using PowerShell / cmd gives an unhelpful error message
2 participants