Replace JSONPath queries with commands #421
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
Describe the change. If there is an associated issue, please include the issue link (e.g. "Closes #xxx"). For UI changes, please also include screenshots.
This is the first of a new set of features geared around using command line tools within the app for transforming and navigation response bodies. The JSONPath query box has been replaced with a mini shell, where you can execute arbitrary commands using the response body as stdin. For example, you can use
jq .args
to filter down to theargs
field.The reason for this is to expand the capabilities of the filtering, without having to add first-class support for everything within Slumber. There will be further improvements to this to make it easier to use and more powerful.
Known Risks
What issues could potentially go wrong with this change? Is it a breaking change? What have you done to mitigate any potential risks?
This is a breaking change, so it will be part of 3.0. This may decrease usability because it requires users to have separate tools installed, but the tradeoff is worth it IMO. We could potentially provide certain tools out of the box anyway to improve it.
QA
How did you test this?
updated existing tests, wrote one new one
Checklist
CONTRIBUTING.md
already?CHANGELOG.md
?