Skip to content

Merge pull request #5 from tshion/feature/2025.01.05 #3

Merge pull request #5 from tshion/feature/2025.01.05

Merge pull request #5 from tshion/feature/2025.01.05 #3

name: Prepare a GitHub release note
on:
push:
branches:
- released
workflow_dispatch:
concurrency:
group: ${{ github.workflow }}
cancel-in-progress: true
jobs:
preparation:
if: ${{ github.ref_type == 'branch' }}
runs-on: ubuntu-24.04
timeout-minutes: 5
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
permissions:
contents: write
id-token: write
pages: write
steps:
# https://github.com/actions/checkout
- uses: actions/checkout@v4
# https://github.com/actions/setup-node
- uses: actions/setup-node@v4
with:
node-version-file: .node-version
cache: npm
cache-dependency-path: ./package-lock.json
- run: npm ci
- name: Generate api docs
run: npm run docs
# https://github.com/actions/configure-pages
- uses: actions/[email protected]
# https://github.com/actions/upload-pages-artifact
- uses: actions/[email protected]
with:
path: out
# https://github.com/actions/deploy-pages
- id: deployment
uses: actions/[email protected]
- name: Get version name
id: meta
run: |
version=$(node -p "require('./package.json').version")
echo "version=$version" >> "$GITHUB_OUTPUT"
- name: Create release notes
env:
GH_TOKEN: ${{ github.token }}
VERSION: ${{ steps.meta.outputs.version }}
run: |
git tag "$VERSION"
git push origin "$VERSION"
gh release create "$VERSION" --generate-notes --title "$VERSION"