Skip to content
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

Feature/add basic cli #206

Merged
merged 8 commits into from
Mar 5, 2024
Merged

Feature/add basic cli #206

merged 8 commits into from
Mar 5, 2024

Conversation

vid
Copy link
Contributor

@vid vid commented Mar 3, 2024

PR description

Adds a basic command line interface. No tests are provided since it just invokes the tested lib and we aren't here to test the runtime.

Checklist

  • [ x] - Added tests
  • [ x] - Ran npm test, ensuring linting passes
  • [x ] - Adjust README documentation if relevant

brettz9
brettz9 previously requested changes Mar 3, 2024
Copy link
Collaborator

@brettz9 brettz9 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think with the suggested changes and an update to the build file, we'd be ready.

src/jsonp-cli.js Outdated Show resolved Hide resolved
src/jsonp-cli.js Outdated Show resolved Hide resolved
package.json Outdated Show resolved Hide resolved
@vid
Copy link
Contributor Author

vid commented Mar 3, 2024

Hi, makes sense. I think it's better not to have two bin options so went with the original package name, but happy to make further improvements. Thanks!

@vid vid requested a review from brettz9 March 3, 2024 23:42
@brettz9
Copy link
Collaborator

brettz9 commented Mar 4, 2024

I'm thinking maybe we should add a jsonpath-plus binary too so that people can use the package name (as you originally did in the docs), as well as the shorter jsonpath.

@vid
Copy link
Contributor Author

vid commented Mar 4, 2024

Oh you're right, I just added the package name as a bin mapping.

@brettz9
Copy link
Collaborator

brettz9 commented Mar 4, 2024

I changed to avoid a dist file (I think CLI users can generally use the latest version) and linted the file. If you want to take a look, I think it should be ready after that.

@vid
Copy link
Contributor Author

vid commented Mar 5, 2024

Makes sense. For completeness (…) I added a files directive.

README.md Outdated Show resolved Hide resolved
package.json Outdated Show resolved Hide resolved
@vid
Copy link
Contributor Author

vid commented Mar 5, 2024

Oh! I wasn't aware of that approach, reverted now.

@brettz9
Copy link
Collaborator

brettz9 commented Mar 5, 2024

So do the changes I added look ok?

@vid
Copy link
Contributor Author

vid commented Mar 5, 2024

Yes, it all "lgtm." Thanks!

@brettz9 brettz9 merged commit c0b51ec into JSONPath-Plus:main Mar 5, 2024
@vid vid deleted the feature/add-basic-cli branch March 5, 2024 13:07
@brettz9
Copy link
Collaborator

brettz9 commented Mar 5, 2024

Thanks for the PR! Released as part of v8.1.0

@brettz9 brettz9 added the Feature label Mar 5, 2024
@vid
Copy link
Contributor Author

vid commented Mar 5, 2024

Thanks for guiding me through it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants