-
Notifications
You must be signed in to change notification settings - Fork 26
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(uikit canary version): update gh actions (#2916)
* chore(uikit canary version): update gh actions * chore(uikit canary version): remove duplicate publishing rule * chore(uikit canary version): add a commit string trigger --------- Co-authored-by: Ddouglasz <[email protected]>
- Loading branch information
Showing
1 changed file
with
3 additions
and
18 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -74,28 +74,13 @@ jobs: | |
env: | ||
GITHUB_TOKEN: ${{ steps.generate_github_token.outputs.token }} | ||
|
||
- name: Create Release Pull Request or Publish to npm | ||
id: changesets | ||
uses: dotansimha/[email protected] | ||
with: | ||
commit: 'ci(changesets): version packages' | ||
publish: yarn changeset publish | ||
version: yarn changeset:version-and-format | ||
createGithubReleases: aggregate | ||
githubReleaseName: v${{ steps.release_version.outputs.VALUE }} | ||
githubTagName: v${{ steps.release_version.outputs.VALUE }} | ||
env: | ||
GITHUB_TOKEN: ${{ steps.generate_github_token.outputs.token }} | ||
SKIP_POSTINSTALL_DEV_SETUP: true | ||
|
||
# Publish canary releases only if the packages weren't published already | ||
# Publish preview releases only if the branch starts with "preview/" and packages weren't published already | ||
- name: Publishing preview releases to npm registry | ||
if: steps.changesets.outputs.published != 'true' && startsWith(github.ref, 'refs/heads/preview/') | ||
if: startsWith(github.ref, 'refs/heads/preview/') && contains(github.event.head_commit.message, '[publish_preview]') | ||
run: | | ||
BRANCH_NAME=$(echo "${GITHUB_REF#refs/heads/}" | tr '/' '-') | ||
DATE=$(date +"%Y%m%d") | ||
git checkout ${{ github.head_ref }} | ||
yarn changeset version --snapshot "0.0.0-${BRANCH_NAME}-${DATE}" | ||
yarn changeset version --snapshot ${BRANCH_NAME}" | ||
yarn changeset publish --tag preview | ||
env: | ||
GITHUB_TOKEN: ${{ steps.generate_github_token.outputs.token }} |