-
Notifications
You must be signed in to change notification settings - Fork 6
44 lines (43 loc) · 1.12 KB
/
publish.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
42
43
44
name: Publish
on:
push:
branches:
- 'main'
workflow_dispatch:
jobs:
publish_npm:
name: Publish
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Prepare repository
run: git checkout main
- uses: pnpm/action-setup@v2
with:
version: 7.25.1
- name: Set Node Version
uses: actions/setup-node@v3
with:
node-version: 18.13.0
cache: 'pnpm'
- name: Install monorepo deps
run: pnpm install
- name: Build packages
run: pnpm build
- name: Type checks
run: pnpm typecheck
- name: Tests
run: pnpm test
- name: Lint
run: pnpm lint
- name: Stash changes
run: git stash
- name: Create Release Pull Request or Publish to npm
uses: changesets/action@c3d88279fd9abe11410de073005e34863f735b1c
with:
publish: pnpm publish-packages
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}