Skip to content

Release

Release #48

Workflow file for this run

name: Release
on:
workflow_dispatch:
inputs:
type:
description: "Release type"
required: true
type: choice
options:
- canary
- patch
- minor
- major
jobs:
npm-publish:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- uses: actions/create-github-app-token@v1
id: app-token
with:
app-id: 906021
private-key: ${{ secrets.FLOWS_BOT_PRIVATE_KEY }}
- uses: actions/checkout@v4
with:
token: ${{ steps.app-token.outputs.token }}
# Make sure the value of GITHUB_TOKEN will not be persisted in repo's config
persist-credentials: false
- uses: pnpm/action-setup@v4
- uses: actions/setup-node@v4
with:
node-version: 20
cache: "pnpm"
- run: git remote set-url origin https://flowsbotapp[bot]:${{ steps.app-token.outputs.token }}@github.com/${{ github.repository }}
- run: git config user.name "flowsbotapp[bot]"
- run: git config user.email "170794745+flowsbotapp[bot]@users.noreply.github.com"
- run: npm config set //registry.npmjs.org/:_authToken=${{ secrets.NPM_TOKEN }}
- run: pnpm install
- run: node scripts/release.js --${{ github.event.inputs.type }}