Closed gruntster closed 5 months ago
This may have been introduced by #504 as that was the only change between v14.3.4 and v14.3.5
See release note
https://github.com/pact-foundation/pact-js-core/releases/tag/v14.3.5
Thanks for the repro, I've tested out a fix
npx --package=@you54f/pact-core@15.0.1 -c 'pact-broker publish "my pact.json" --consumer-app-version=1'
it doesn't set shell unless its windows, and if shell value is set, it escapes arguments based on the detected shell
https://github.com/YOU54F/pact-js-core/pull/45/files
will get a pr raised against this repo shortly
Fix released in 14.3.7
https://github.com/pact-foundation/pact-js-core/releases/tag/v14.3.7
Software versions
Issue Checklist
Please confirm the following:
Expected behaviour
CLIs handle quoted parameters with spaces, e.g.
"my pact.json"
, as a single parameter.Actual behaviour
Since v14.3.5, CLIs now treat quoted parameters as individual parameters, e.g.
"my pact.json"
is treated as two parametersmy
pact.json
.Steps to reproduce
An easy way to reproduce the issue is to run a CLI from v14.3.5 or v14.3.6 using npx. e.g.
npx --package=@pact-foundation/pact-core@14.3.5 -c 'pact-broker publish "my pact.json" --consumer-app-version 1'
The error output highlights that the filename (in bold) has been truncated at the space.
Compared to running the same command with v14.3.4.
npx --package=@pact-foundation/pact-core@14.3.4 -c 'pact-broker publish "my pact.json" --consumer-app-version 1'