chore(release): prepare for v3.3.4 #28
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Release | |
on: | |
push: | |
tags: ['v*.*.*'] | |
permissions: | |
contents: read | |
jobs: | |
check-dist: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-node@v4 | |
with: | |
cache: npm | |
node-version-file: .node-version | |
- run: npm ci | |
- run: npm run prepack | |
- name: Check dist | |
run: git diff --text --ignore-all-space --exit-code -- dist | |
release: | |
needs: check-dist | |
runs-on: ubuntu-latest | |
permissions: | |
contents: write | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
ref: ${{ github.ref_name }} | |
- run: npm pack --ignore-scripts | |
- name: Generate release notes | |
run: >- | |
git for-each-ref "${GITHUB_REF}" --format='%(contents:body)' | | |
tee RELEASENOTES.md | |
- name: Release | |
env: | |
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
GH_REPO: ${{ github.repository }} | |
run: >- | |
gh release create --draft -F RELEASENOTES.md -- "${GITHUB_REF_NAME}" *.tgz |