release 0.0.5 #45
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
on: | |
push: | |
branches: | |
- main | |
name: Build, test, release | |
jobs: | |
turbo: | |
name: Publish to npm and release on github | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: pnpm/action-setup@v2 | |
with: | |
version: 7.13.6 | |
- name: Setup node | |
uses: actions/setup-node@v3 | |
with: | |
node-version: 16 | |
check-latest: true | |
cache: pnpm | |
- name: Install deps for root and repo-utils | |
run: pnpm i --filter=repo-utils --filter=whop-sdk-ts | |
- name: Build repo-utils | |
run: pnpm turbo build --filter=repo-utils | |
- name: Install all packages | |
run: pnpm i | |
- name: Check package.json for version increase | |
id: check | |
run: node packages/repo-utils/dist/can-publish.js | |
- run: echo "//registry.npmjs.org/:_authToken=$NPM_TOKEN" >> ~/.npmrc | |
if: steps.check.outputs.can-publish == 'true' | |
env: | |
NPM_TOKEN: ${{ secrets.NPM_TOKEN }} | |
- name: Run turbo release flow | |
run: pnpm turbo release ${{ steps.check.outputs.filter }} | |
if: steps.check.outputs.can-publish == 'true' | |
- name: Github Release | |
run: node packages/repo-utils/dist/release.js | |
if: steps.check.outputs.can-publish == 'true' | |
env: | |
GITHUB_TOKEN: ${{ github.token }} | |
VERSION: ${{ steps.check.outputs.version }} | |
INITIAL_COMMIT: 5a774a648de040bd1c36ca04e759e37a958a93e6 |