Skip to content

Release

Release #5

Workflow file for this run

name: Release
on:
workflow_dispatch:
inputs:
version:
description: "Version to release (e.g., 1.0.0)"
required: true
type: string
permissions:
contents: write
jobs:
release:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
token: ${{ secrets.GITHUB_TOKEN }}
- run: corepack enable
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: "22"
cache: "yarn"
- name: Install dependencies
run: yarn install --frozen-lockfile
- name: Configure Git
run: |
git config --local user.email "action@github.com"
git config --local user.name "GitHub Action"
- name: Update package.json version
run: |
npm version ${{ github.event.inputs.version }} --no-git-tag-version
git add package.json
git commit -m "Release v${{ github.event.inputs.version }}"
- name: Push changes
run: git push
- name: Create GitHub Release
uses: softprops/action-gh-release@v2
with:
tag_name: v${{ github.event.inputs.version }}
name: Release v${{ github.event.inputs.version }}
draft: false
prerelease: false
generate_release_notes: true
make_latest: true