-
Notifications
You must be signed in to change notification settings - Fork 673
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
Multiple commands in build.command fail on Linux #236
Comments
Great catch. Will fix. |
threepointone
added a commit
that referenced
this issue
Jan 26, 2022
We were running custom builds as a regular command with `execa`. This would fail whenever we tried to run compound commands like `cargo install -q worker-build && worker-build --release` (via #236). The fix is to use `shell: true`, so that the command is run in a shell and can thus use bash-y syntax like `&&`, and so on. I also switched to using `execaCommand` which splits a command string into parts correctly by itself.
threepointone
added a commit
that referenced
this issue
Jan 26, 2022
We were running custom builds as a regular command with `execa`. This would fail whenever we tried to run compound commands like `cargo install -q worker-build && worker-build --release` (via #236). The fix is to use `shell: true`, so that the command is run in a shell and can thus use bash-y syntax like `&&`, and so on. I also switched to using `execaCommand` which splits a command string into parts correctly by itself.
Merged
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
For example, with a rust project:
I get:
Indicating cargo is being passed
worker-build --release
as an argument.I think this is caused here, and it should be something like
execva('sh', ['-c', commandPieces.join(" ")])
This looks like it would also affect mac and windows, though I can't test either.
Using
v0.0.7
with nodev16.13.1
The text was updated successfully, but these errors were encountered: