ci: try to get auto publish work
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
parent
0edf20354f
commit
6eda801b1c
15
.drone.yml
15
.drone.yml
@ -2,6 +2,12 @@ kind: pipeline
|
||||
type: docker
|
||||
name: default
|
||||
|
||||
when:
|
||||
event:
|
||||
- push
|
||||
- pull_request
|
||||
- tag
|
||||
|
||||
steps:
|
||||
|
||||
- name: build (rust)
|
||||
@ -13,9 +19,18 @@ steps:
|
||||
|
||||
- name: build (node)
|
||||
image: node:22.9-bookworm
|
||||
environment:
|
||||
NPM_TOKEN:
|
||||
from_secret: NPM_TOKEN
|
||||
commands:
|
||||
- corepack enable
|
||||
- cd um_wasm_loader
|
||||
- pnpm i
|
||||
- BUILD_SKIP_WASM_PACK=1 pnpm build
|
||||
- pnpm pack
|
||||
- |
|
||||
if [ -n "${DRONE_TAG}" ]; then
|
||||
./ci_publish.sh
|
||||
else
|
||||
echo "skip package publish"
|
||||
fi
|
||||
|
4
um_wasm_loader/ci_publish.sh
Normal file
4
um_wasm_loader/ci_publish.sh
Normal file
@ -0,0 +1,4 @@
|
||||
#!/bin/bash
|
||||
|
||||
echo '//git.unlock-music.dev/api/packages/um/npm/:_authToken=${NPM_TOKEN}' > $HOME/.npmrc
|
||||
pnpm publish --access=public
|
Loading…
Reference in New Issue
Block a user