-
Notifications
You must be signed in to change notification settings - Fork 0
41 lines (41 loc) · 993 Bytes
/
release.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
name: Release
on:
push:
branches: main
concurrency: release
permissions:
contents: read
jobs:
ci:
name: CI
permissions:
contents: read
security-events: write
if: (!startsWith(github.event.head_commit.message, 'chore(release):'))
uses: ./.github/workflows/ci.yml
cd:
name: CD
if: (!startsWith(github.event.head_commit.message, 'chore(release):'))
runs-on: ubuntu-latest
timeout-minutes: 30
needs:
- ci
steps:
- name: Checkout
uses: actions/checkout@v4.1.7
with:
persist-credentials: false
- name: Set up node
uses: actions/setup-node@v4.0.2
with:
node-version-file: .nvmrc
cache: npm
- name: Install packages
run: npm ci
- name: Run build
run: npm run build
- name: Release
run: npx semantic-release
env:
GITHUB_TOKEN: ${{secrets.RELEASE_TOKEN}}
NPM_TOKEN: ${{secrets.NPM_TOKEN}}