-
-
Notifications
You must be signed in to change notification settings - Fork 15
(windows) - plugins do not exit cleanly, if invoked from batch/ps1 script #73
Copy link
Copy link
Closed
Description
xy problem.
Trying to get the pact-avro-plugin working on windows, with Std::Process::Command in rust.
It uses a batch file, which means we get a terminate batch file y/n prompt, and it fails to exit cleanly, leaving test to hang unless cancelled via task manager.
We can replace it with a powershell script, to avoid the batch file prompt, but there is no way to invoke the powershell script, with powershell directly in the current impl, as we try and run the plugin entrypoint, from the plugins current working directory.
| let mut child_command = Command::new(path.clone()); |
could we potentially
- if we detect a *.ps1 script, invoke powershell -Command `
- If this does solve it, it may be worth me dropping a pr into the https://github.com/sbt/sbt-native-packager project for it to also emit ps1 files as well as its current bat files.
- if
argsare supplied, they are not able to be provided on a case by case basis (so only for windows). I anticipated I may need extra args, but only in windows.
This follows on from austek/pact-avro-plugin#42
Where I now have the plugin starting and the tests passing, but the plugin is just failing to cleanly exit.
open to other ideas :)
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels