-
Notifications
You must be signed in to change notification settings - Fork 680
ci: add master branch to release action #2094
Conversation
@@ -76,7 +95,7 @@ jobs: | |||
# this needs `--no-verify-access` until https://github.com/lerna/lerna/issues/2788 is fixed | |||
- name: Release to npm | |||
run: | | |||
$(npm bin)/lerna publish from-package --yes --dist-tag ${GITHUB_REF##*/} --pre-dist-tag ${GITHUB_REF##*/} --no-verify-access | |||
$(npm bin)/lerna publish from-package --yes --dist-tag ${TAG} --pre-dist-tag ${TAG} --no-verify-access |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@cds-amal how does this line look to you?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
IT looks ok to me as long as lerna is installed :) how did the action run?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It ran! This step wasn't included in the test action because it has side effects.
echo "TAG=${GITHUB_REF##*/}" >> $GITHUB_ENV | ||
|
||
- name: Update package versions for latest release (master) | ||
if: ${{ env.TAG == 'latest' }} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
since after if: ${{ github.ref == 'refs/heads/master' }}
we set the tag to 'latest'
, can't we just remove this if statement and include the following run: $(npm bin)/lerna version patch --no-git-tag-version --no-push --yes --exact
inside of it?
Not particularly important, but could be a slight improvement.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, we could do that, and avoid these weird if:
s would be kinda nice. The "step" would just be doing two things now. It'd be named something like "Set TAG for master to latest and update versions for master".
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good, pending tests outcome
No description provided.