Skip to content

Release

Release #2

Workflow file for this run

name: Release
on:
workflow_dispatch:
inputs:
bump:
description: "Bump Type"
required: true
type: choice
options:
- patch
- minor
- major
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
publish:
permissions:
contents: write
id-token: write
runs-on: ubuntu-latest
timeout-minutes: 15
steps:
- name: Checkout Source Code
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup Bun
uses: oven-sh/setup-bun@v1
with:
bun-version: latest
- name: Install Dependencies
run: bun install --frozen-lockfile
- name: Set Git User
run: |
git config user.name "${GITHUB_ACTOR}"
git config user.email "${GITHUB_ACTOR}@users.noreply.github.com"
- name: Set NPM Config
run: npm config set //registry.npmjs.org/:_authToken "${NPM_TOKEN}"
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
- name: Bump version
run: npm version ${{ github.event.inputs.bump }}
- name: Build
run: bun run build
- name: Publish
run: npm publish --provenance --access public
- name: Commit
run: git push