-
Notifications
You must be signed in to change notification settings - Fork 3
48 lines (39 loc) · 1.28 KB
/
Copy pathrelease.yaml
File metadata and controls
48 lines (39 loc) · 1.28 KB
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
name: Release and Publish
on:
push:
branches:
- main
# Frontend source is delivered by chatgpt-plugin, not the npm package.
# A frontend-only commit therefore must not create a release PR or publish.
paths-ignore:
- "frontend/**"
permissions:
contents: write
pull-requests: write
jobs:
release-please:
runs-on: ubuntu-latest
steps:
- uses: googleapis/release-please-action@v4
id: release
with:
release-type: node
- uses: actions/checkout@v4
if: ${{ steps.release.outputs.release_created }}
- uses: actions/setup-node@v4
if: ${{ steps.release.outputs.release_created }}
with:
node-version: 20
registry-url: "https://registry.npmjs.org"
- uses: pnpm/action-setup@v4
if: ${{ steps.release.outputs.release_created }}
with:
version: 9
- run: pnpm install
if: ${{ steps.release.outputs.release_created }}
- run: pnpm run prepublishOnly
if: ${{ steps.release.outputs.release_created }}
- run: pnpm publish --access public --no-git-checks --//registry.npmjs.org/:_authToken=${NODE_AUTH_TOKEN}
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
if: ${{ steps.release.outputs.release_created }}