Skip to content

Merge pull request #6 from llmhut/v0.2.1 #8

Merge pull request #6 from llmhut/v0.2.1

Merge pull request #6 from llmhut/v0.2.1 #8

Workflow file for this run

name: Release
on:
push:
tags:
- 'v*'
jobs:
publish:
name: Publish to npm
runs-on: ubuntu-latest
permissions:
contents: write
id-token: write
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 20
cache: 'npm'
registry-url: 'https://registry.npmjs.org'
- run: npm ci
- run: npm test
- run: npm run build
- name: Publish
run: |
if [[ "${{ github.ref_name }}" == *"-alpha"* || "${{ github.ref_name }}" == *"-beta"* || "${{ github.ref_name }}" == *"-rc"* ]]; then
npm publish --provenance --access public --tag alpha
else
npm publish --provenance --access public
fi
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
- name: Create GitHub Release
uses: softprops/action-gh-release@v2
with:
generate_release_notes: true