name: Release on: workflow_dispatch: inputs: VERSION_BUMP: description: 'The version bump' type: choice options: - major - minor - patch default: minor required: true SKIP_NPM: description: 'Skip publishing to NPM?' type: boolean default: false required: false jobs: release: runs-on: ubuntu-latest concurrency: group: release-${{ github.repository }}-${{ github.ref_name }} cancel-in-progress: false environment: release permissions: contents: write id-token: write steps: - name: Checkout code uses: actions/checkout@v6 with: persist-credentials: false - name: Setup Node.js version uses: actions/setup-node@v6 with: node-version: 24 registry-url: 'https://registry.npmjs.org/' - name: Install dependencies run: | npm install -g yarn@1 yarn install --frozen-lockfile - name: Configure git run: | git config user.name "Uphold" git config user.email "bot@uphold.com" git config --global url.https://${{ secrets.RELEASE_GITHUB_TOKEN }}@github.com/.insteadOf https://github.com/ - name: Generate release and publish to npm env: GITHUB_TOKEN: ${{ secrets.RELEASE_GITHUB_TOKEN }} if: ${{ github.event.inputs.SKIP_NPM == 'false' }} run: npm run release -- --increment "${{ github.event.inputs.VERSION_BUMP }}" -V - name: Generate release without publishing to npm env: GITHUB_TOKEN: ${{ secrets.RELEASE_GITHUB_TOKEN }} if: ${{ github.event.inputs.SKIP_NPM == 'true' }} run: npm run release -- --increment "${{ github.event.inputs.VERSION_BUMP }}" -V --no-npm.publish