Skip to content

Merge pull request #770 from nteract/sigh-mcp #28

Merge pull request #770 from nteract/sigh-mcp

Merge pull request #770 from nteract/sigh-mcp #28

Workflow file for this run

name: Release
on:
push:
tags: ["v*"]
jobs:
publish:
runs-on: ubuntu-latest
permissions:
contents: read
id-token: write
steps:
- name: Checkout source code
uses: actions/checkout@v6
- name: Use Node.js
uses: actions/setup-node@v6
with:
node-version: 22.x
cache: "npm"
registry-url: "https://registry.npmjs.org"
- name: Install dependencies
run: npm install --legacy-peer-deps
- name: Build library
run: npm run dist
- name: Build MCP server
run: npm run build:mcp
- name: Run tests with coverage
run: npx vitest run --coverage
- name: Run type check
run: npm run typescript
- name: Determine npm dist-tag
id: dist-tag
run: |
VERSION=$(node -p "require('./package.json').version")
if echo "$VERSION" | grep -qE '[-](alpha|beta|rc)'; then
echo "tag=beta" >> "$GITHUB_OUTPUT"
else
echo "tag=latest" >> "$GITHUB_OUTPUT"
fi
- name: Publish to npm
run: npm publish --provenance --access public --tag ${{ steps.dist-tag.outputs.tag }}
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}