Skip to content

release: v0.5.0

release: v0.5.0 #8

Workflow file for this run

name: Publish and Create Release
on:
push:
tags:
- 'v*.*.*'
permissions:
contents: write
id-token: write
jobs:
publish:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: '22'
- run: npm install -g npm@11.5.1
- run: corepack enable
- run: corepack prepare yarn@4.15.0 --activate
- uses: actions/cache@v4
with:
path: |
.yarn/cache
node_modules
key: ${{ runner.os }}-yarn-${{ hashFiles('yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
- run: yarn install --immutable
- run: yarn lint
- run: yarn typecheck
- run: yarn test --run
- run: yarn build
- name: Copy LICENSE into each package
run: |
cp LICENSE packages/mejiro/
cp LICENSE packages/mejiro-react/
cp LICENSE packages/mejiro-vue/
# Publish in dependency order: core first, then framework packages.
# `yarn pack` resolves `workspace:^` deps to a concrete `^X.Y.Z` range
# in the tarball, so `npm publish <tarball>` uploads a clean manifest.
- name: Publish @libraz/mejiro
working-directory: packages/mejiro
run: |
yarn pack -o package.tgz
npm publish package.tgz --access public
- name: Wait for registry propagation
run: sleep 15
- name: Publish @libraz/mejiro-react
working-directory: packages/mejiro-react
run: |
yarn pack -o package.tgz
npm publish package.tgz --access public
- name: Publish @libraz/mejiro-vue
working-directory: packages/mejiro-vue
run: |
yarn pack -o package.tgz
npm publish package.tgz --access public
- name: Create GitHub Release
uses: softprops/action-gh-release@v2
with:
name: Release ${{ github.ref_name }}
tag_name: ${{ github.ref_name }}
body: |
Automated release for ${{ github.ref_name }}.
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}