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

Publish to npm #14

Merged
merged 10 commits into from
Apr 1, 2020
Merged

Publish to npm #14

merged 10 commits into from
Apr 1, 2020

Conversation

djfarrelly
Copy link
Contributor

@djfarrelly djfarrelly commented Mar 28, 2020

Purpose

The binary executable is great, but using npm is an easier way to consume, upgrade and publish updates to this package. Package on npm

$ npm install -g @bufferapp/kubesecret
$ kubesecret -V
0.4.0

This also closes #3.

Background

The binary method felt the most usable when this package was written in golang and we didn't want to use npm as a delivery method. We used pkg before for other binaries (buffer-dev) because we wanted them to be more easily usable for non-developers, but since this is a developer tool, I think it's ok to assume everyone on the engineering team has node and npm installed 😄

Review

Hey @kiriappeee, I was thinking of making another addition to this CLI and thought of this idea. We could continue to build + distribute the binary, but this might be simpler for folks on the team to download the binary off of Github and move it into their PATH. What do you think?

@djfarrelly djfarrelly requested a review from kiriappeee March 28, 2020 15:55
Copy link
Member

@kiriappeee kiriappeee left a comment

Choose a reason for hiding this comment

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

Tested. Looks great to me @djfarrelly . Thanks for getting this up 👍

@kiriappeee
Copy link
Member

Quick aside, this isn't necessary for this PR. Might be good to specify minimum versions of node for this package.

@djfarrelly
Copy link
Contributor Author

2 great ideas @kiriappeee!

  • I just specified the min version at Node 10. This should work w/ Node 8.x w/ async/await support, but 8 is not in LTS anymore so 10 should be a good minimum 😁.
  • Good catch on keeping the -V flag correct, I decided to take your idea and require the package.json file directly to ensure that the version is always in sync to remove developer error in the future!

@kiriappeee, do you have an npm username? I want to add you to our npm org so you can publish packages there 😄

@djfarrelly djfarrelly merged commit 856f733 into master Apr 1, 2020
@djfarrelly djfarrelly deleted the task/npm-package branch April 1, 2020 17:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add README w/ install info
2 participants