-
Notifications
You must be signed in to change notification settings - Fork 1
65 lines (54 loc) · 1.44 KB
/
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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
name: Release
on:
push:
branches:
- main
concurrency: ${{ github.workflow }}-${{ github.ref }}
permissions:
id-token: write
contents: write
pull-requests: write
jobs:
prepare:
name: Prepare
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Setup Node.js
uses: ./.github/actions/setup-node
- name: Create Release Pull Request
id: changesets
uses: changesets/action@v1
with:
version: yarn ci:version
commit: 'chore: version packages'
title: 'chore: version packages'
createGithubReleases: false
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
publish:
name: Publish
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Setup Node.js
uses: ./.github/actions/setup-node
- name: Setup PDFium
uses: ./.github/actions/setup-pdfium
with:
target_os: wasm
target_cpu: wasm
static_lib: true
enable_v8: false
debug: false
- name: Build packages
run: |
yarn run test
yarn build:packages
- name: Publish to NPM
run: |
echo "//registry.npmjs.org/:_authToken=${{ secrets.NPM_TOKEN }}" > .npmrc
yarn config set npmAuthToken ${{ secrets.NPM_TOKEN }}
yarn ci:publish
rm ".npmrc"
yarn config unset npmAuthToken