Skip to content

chore(release): v0.10.13 [skip-release] #22

chore(release): v0.10.13 [skip-release]

chore(release): v0.10.13 [skip-release] #22

Workflow file for this run

name: Release
on:
push:
branches:
- main
workflow_dispatch:
inputs:
semver:
description: 'Version increment type'
required: true
default: 'patch'
type: choice
options:
- patch
- minor
- major
jobs:
release:
runs-on: ubuntu-latest
permissions:
contents: write
issues: write
pull-requests: write
id-token: write
if: github.ref == 'refs/heads/main' && !contains(github.event.head_commit.message, '[skip-release]')
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 0
token: ${{ secrets.GH_TOKEN }}
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 20.x
- name: Install pnpm
uses: pnpm/action-setup@v2
with:
version: latest
- name: Install dependencies
run: pnpm install --frozen-lockfile
- name: Run validation
run: pnpm validate
- name: Configure NPM authentication
run: npm config set //registry.npmjs.org/:_authToken $NPM_TOKEN
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
- name: Configure Git
run: |
git config user.name "${GITHUB_ACTOR}"
git config user.email "${GITHUB_ACTOR}@users.noreply.github.com"
- name: Set SemVer
id: set_semver
run: |
if [ "${{ github.event_name }}" == "workflow_dispatch" ]; then
echo "SEMVER=${{ github.event.inputs.semver }}" >> $GITHUB_ENV
else
echo "SEMVER=patch" >> $GITHUB_ENV
fi
- name: Execute Release
run: pnpm release ${{ env.SEMVER }} --ci
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GH_TOKEN }}