Skip to content

v16.0.2

v16.0.2 #62

Workflow file for this run

name: Release
on:
release:
types:
- published
env:
FORCE_COLOR: 2
jobs:
build:
runs-on: ubuntu-latest
permissions:
contents: write
id-token: write
strategy:
matrix:
node:
- latest
steps:
- name: Get version from tag
id: tag_name
run: echo "current_version=${GITHUB_REF#refs/tags/v}" >> $GITHUB_OUTPUT
- name: Check out repository
uses: actions/[email protected]
- name: Set up Node.js
uses: actions/[email protected]
with:
node-version: ${{ matrix.node }}
registry-url: "https://registry.npmjs.org"
- name: Get changelog entry
uses: mindsers/[email protected]
id: changelog_reader
with:
version: ${{ steps.tag_name.outputs.current_version }}
- name: Update release with changelog contents
uses: softprops/[email protected]
id: release_updater
with:
body: ${{ steps.changelog_reader.outputs.changes }}
- name: Create discussion for release
run: |
gh api \
--method PATCH \
-H "Accept: application/vnd.github+json" \
/repos/${{ github.repository }}/releases/${{ steps.release_updater.outputs.id }} \
-f discussion_category_name='Announcements'
env:
GITHUB_TOKEN: ${{ secrets.RELEASE_TOKEN }}
- run: npm ci
- run: npm whoami && npm --ignore-scripts publish --access public --provenance
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_PUBLISH_TOKEN }}