Skip to content

Publish to npm#14

Merged
djfarrelly merged 10 commits intomasterfrom
task/npm-package
Apr 1, 2020
Merged

Publish to npm#14
djfarrelly merged 10 commits intomasterfrom
task/npm-package

Conversation

@djfarrelly
Copy link
Copy Markdown
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
Copy Markdown
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
Copy Markdown
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
Copy Markdown
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