Skip to content

Commit

Permalink
Merge pull request #8 from lottie/mf/fix-release-3
Browse files Browse the repository at this point in the history
ci: fix release script
  • Loading branch information
Aidosmf authored May 24, 2024
2 parents 5c62492 + a05fd88 commit 620c795
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 7 deletions.
12 changes: 7 additions & 5 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,11 @@ jobs:
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}

- name: Build
run: yarn build
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}

- name: Create .npmrc
run: |
cat << EOF > "$HOME/.npmrc"
Expand All @@ -43,12 +48,9 @@ jobs:
id: changesets
uses: changesets/action@v1
with:
version: yarn release
version: yarn changelog:version
publish: yarn changelog:publish
env:
NPM_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Publish to NPM
if: steps.changesets.outputs.hasChangesets == 'false'
run: npm publish --@lottie-animation-community:registry=https://registry.npmjs.org
3 changes: 1 addition & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,7 @@
"changelog": "changeset add",
"changelog:check": "changeset status --since=main",
"changelog:version": "changeset version",
"changelog:publish": "yarn build && changeset publish",
"release": "yarn changelog:version && yarn changelog:publish"
"changelog:publish": "changeset publish"
},
"repository": {
"type": "git",
Expand Down

0 comments on commit 620c795

Please sign in to comment.