-
Notifications
You must be signed in to change notification settings - Fork 3
39 lines (33 loc) · 916 Bytes
/
deploy.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
on:
push:
branches: [master]
paths:
- 'lib/**'
- 'backend/version'
jobs:
deploy:
name: Deploy Package
runs-on: ubuntu-latest
permissions:
contents: read
steps:
- name: Checkout
uses: actions/checkout@v4
- uses: jdx/mise-action@v2
- name: create .npmrc
run: |
echo "//registry.npmjs.org/:_authToken=\${NODE_AUTH_TOKEN}
registry=https://registry.npmjs.org/
always-auth=true" > ~/.npmrc
- name: Update Version
run: |
echo -n "-$(git rev-parse --short HEAD)" >> backend/version && \
node util/versioning.mjs update package.json lib/package.json
- name: Install, Build & Publish
working-directory: lib
env:
NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}
run: |
pnpm install && \
pnpm build && \
pnpm publish --no-git-checks --tag prerelease