-
Notifications
You must be signed in to change notification settings - Fork 13
39 lines (32 loc) · 1.07 KB
/
publish.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
name: Publish
on:
workflow_dispatch:
permissions:
contents: write
jobs:
common:
runs-on: ubuntu-latest
defaults:
run:
working-directory: ./
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: 16
registry-url: https://registry.npmjs.org/
cache-dependency-path: ./package-lock.json
- run: npx lerna@6 bootstrap
- run: npx lerna@6 run build
- name: Create release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
echo " - Split main [sdk-nestjs](https://www.npmjs.com/package/@multiversx/sdk-nestjs) package into multiple packages" >> notes.txt
echo "" >> notes.txt
RELEASE_TAG=v$(node -p "require('./lerna.json').version")
gh release create $RELEASE_TAG --target=$GITHUB_SHA --title="$RELEASE_TAG" --generate-notes --notes-file=notes.txt
- name: Publish to npmjs
env:
NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}
run: npx lerna@6 publish from-package --yes