CI: Workflow to Publish to npm if Package Version is Changed #7
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
As per #6, a workflow that automatically pushes packages to npm when it detects a version changed is a good addition, because some developers that update these packages might not have the permissions to publish themselves, and it makes their jobs easier by not having to worry about uploading the package once it's updated - that is now automated.
Closes #6
Notes:
NODE_AUTH_TOKEN
must be added, and it should contain the npm auth token of thestacks
organisation (Automation
type, so it can bypass2FA
).--access=public
option fornpm publish
command because I couldn't test it with private packages. This will need a discussion with Jesse so I can properly update the command.Workflow runs:
@stacks/clarunit
): https://github.com/BowTiedDevOps/stacks-test-tools/actions/runs/8554791139commitbranch of this PR (added job names so it shows them instead of the ids): https://github.com/BowTiedDevOps/stacks-test-tools/actions/runs/8555076098NPM Profile (Published Packages): https://www.npmjs.com/~bowtieddevops
Tag @wileyj and @hugocaillard because I can't add reviewers on this repo.