question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Feature Request: Create binstubs for pact-standalone binaries

See original GitHub issue

AS a user who wants to integrate to the latest Pact CLI features IT would be useful to be able to easily reference the Pact binaries (e.g. pact, pact-broker pact-message etc.) SO that I can use them without having to write JS wrappers, or wait for them to be included in the JS library

Example use case

Prior to deployment, we often run the can-i-deploy tool to check if it’s safe to release either a consumer or a provider. Bash is an appropriate tool for this. It’s hard to find the CLI tools if you don’t know what you’re doing, but it is possible:

package.json:

"can-i-deploy:consumer": "$(find ./node_modules -name pact-broker | grep -e 'bin/pact-broker$' | head -n 1) can-i-deploy --pacticipant SNSPactEventConsumer --latest --broker-base-url https://test.pact.dius.com.au --broker-username xxx --broker-password yyy",

Typically, I just install the CLI tools into my Docker container and add them to the path. But it would be nice if I could just go:

package.json:

can-i-deploy:consumer": "pact-broker can-i-deploy --pacticipant SNSPactEventConsumer --latest --broker-base-url https://test.pact.dius.com.au --broker-username xxx --broker-password yy

I imagine the ./node_modules/.bin dir might look like:

ls ./node_modules/.bin
pact_broker -> ./node_modules/@pact-foundation/pact-node/standalone/darwin-1.33.1/bin/pact-broker
pact -> ./node_modules/@pact-foundation/pact-node/standalone/darwin-1.33.1/bin/pact
...

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Reactions:2
  • Comments:9 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
amr-labibcommented, Aug 9, 2018

Yes, I could try, it would be my first github PR though. I am reading the contribution guidelines now.

0reactions
TimothyJonescommented, May 28, 2019

I think this is now fixed by #161 (thanks @mefellows! Much appreciated!)

Read more comments on GitHub >

github_iconTop Results From Across the Web

pact-js-core/CHANGELOG.md at master - GitHub
Core binaries for pact-js, a Contract Testing Framework. ... binstubs: expose pact standalone binaries as alternative CLI (02f16cc); binstubs: expose pact ...
Read more >
bundle binstubs - Bundler
Binstubs are scripts that wrap around executables. Bundler creates a small Ruby file (a binstub) that loads Bundler, runs the command, and puts...
Read more >
Changelog | Pact Docs
Make request tracer log in debug instead of trace (24742e4) ... wrapper in favour of exposing the pact-standalone binaries as binstubs.
Read more >
Bundler and wrong binstubs? - ruby - Stack Overflow
Bundler is using a binstub that was created for a different gem. This is deprecated, ; rails has no executables, but you may...
Read more >
Why aren't you using binstubs yet? - Ajit Singh
When you create a new rails 5 project, by default you will have some binary files under /bin folder. Here is how the...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found