-
Notifications
You must be signed in to change notification settings - Fork 7
52 lines (52 loc) · 1.34 KB
/
js-beta.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
name: Build and release beta
on:
push:
branches:
- 'main'
permissions:
contents: write
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name:
uses: bufbuild/buf-setup-action@v1
with:
version: latest
- run: buf --version
- name: setup node
uses: actions/setup-node@v4
with:
node-version: '20.x'
- uses: pnpm/action-setup@v4
name: Install pnpm
with:
version: 9
- uses: actions/create-github-app-token@v1
id: app-token
with:
app-id: ${{ vars.MYNA_APP_ID }}
private-key: ${{ secrets.MYNA_APP_SECRET }}
- name: 'bot: version bump'
uses: 'phips28/gh-action-bump-version@master'
env:
GITHUB_TOKEN: ${{ steps.app-token.outputs.token }}
PACKAGEJSON_DIR: 'js'
with:
version-type: 'prerelease'
commit-message: 'bump version'
skip-tag: 'true'
skip-commit: 'false'
- name: Build and publish
run: |
bash generate.sh
cd js
buf generate
pnpm install
pnpm run build
npm config set '//registry.npmjs.org/:_authToken' $NPM_TOKEN
npm publish
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}