Skip to content

chore: release v0.2.6 #33

chore: release v0.2.6

chore: release v0.2.6 #33

Workflow file for this run

name: 馃帀 Release
on:
push:
tags:
- 'v*'
jobs:
release:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Install pnpm
uses: pnpm/action-setup@v2
- name: Set node
uses: actions/setup-node@v3
with:
node-version: 18.x
cache: pnpm
- name: Install
run: pnpm install --no-frozen-lockfile
- name: Set Timezone
run: |
sudo ln -sf /usr/share/zoneinfo/Asia/Shanghai /etc/localtime
echo "Asia/Shanghai" | sudo tee /etc/timezone
date
shell: bash
- name: Build
run: pnpm run build
- name: unit test
run: pnpm run test:unit
- name: Set npmrc for components
run: |
for package in $(find components/* -maxdepth 1 -type d); do
echo "//registry.npmjs.org/:_authToken=${NPM_TOKEN}" > ${package}/.npmrc
done
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
- name: Set npmrc for root preset
run: echo "//registry.npmjs.org/:_authToken=${NPM_TOKEN}" > preset/.npmrc
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
- name: Set npmrc for root utils
run: echo "//registry.npmjs.org/:_authToken=${NPM_TOKEN}" > utils/.npmrc
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
- name: Set npmrc for root packages
run: echo "//registry.npmjs.org/:_authToken=${NPM_TOKEN}" > .npmrc
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
- name: Publish to npm
run: pnpm run publish:script
- run: npx changelogithub
continue-on-error: true
env:
GITHUB_TOKEN: ${{secrets.GH_TOKEN}}