Publish #51
This file contains hidden or 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
| name: Publish | |
| on: | |
| workflow_dispatch: | |
| concurrency: ${{ github.workflow }}-${{ github.ref }} | |
| jobs: | |
| publish: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Main Only | |
| if: ${{ github.ref != 'refs/heads/main' }} | |
| run: exit 1 | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| with: | |
| ssh-key: ${{ secrets.GH_DEPLOY_KEY }} | |
| github-server-url: 'ssh://[email protected]' | |
| - name: Setup Anchor | |
| uses: ./.github/actions/anchor | |
| - name: Install dependencies | |
| run: yarn install | |
| - name: Determine New Versions | |
| run: yarn changeset version | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| - name: Update Cargo Version Numbers | |
| uses: ./.github/actions/sync | |
| - name: Publish Packages | |
| run: yarn deploy | |
| env: | |
| NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} | |
| CARGO_REGISTRY_TOKEN: ${{ secrets.CRATES_TOKEN }} | |
| - name: Tag Release | |
| run: yarn changeset tag | |
| - name: Push Changes | |
| uses: ./.github/actions/push | |
| with: | |
| branch: main | |
| message: Publish Packages | |
| user: changests[bot] |