-
Notifications
You must be signed in to change notification settings - Fork 1
54 lines (50 loc) · 1.43 KB
/
ci.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
45
46
47
48
49
50
51
52
53
54
name: ci
on:
push:
branches:
- main
- beta
pull_request:
types: [opened, synchronize, reopened]
concurrency:
group: ${{ github.ref }}-${{ github.head_ref }}
cancel-in-progress: true
env:
CI: true
NODE_VERSION: 20
PNPM_CACHE_FOLDER: .pnpm-store
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout Commit
uses: actions/checkout@v3
- uses: pnpm/action-setup@v2
with:
version: 8
run_install: |
- recursive: true
args: [--frozen-lockfile, --strict-peer-dependencies]
- args: [--global, prettier, typescript, rimraf, turbo]
- name: Use Node.js
uses: actions/setup-node@v3
with:
cache: 'pnpm'
registry-url: 'https://registry.npmjs.org'
node-version: ${{ env.NODE_VERSION }}
- name: setup pnpm config
run: pnpm config set store-dir $PNPM_CACHE_FOLDER
- name: Run build
run: |
pnpm run ci
- name: create and publish versions
uses: changesets/action@v1
if: github.ref == 'refs/heads/main' || github.ref == 'refs/heads/beta'
with:
version: pnpm ci:version
commit: 'chore: update versions'
title: 'chore: update versions'
publish: pnpm ci:publish
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
npm_config__authtoken: ${{ secrets.NPM_TOKEN }}