File tree 1 file changed +9
-10
lines changed
1 file changed +9
-10
lines changed Original file line number Diff line number Diff line change 6
6
workflow_dispatch : {}
7
7
jobs :
8
8
publish :
9
- # if: github.event.pull_request.merged == true
9
+ if : github.event.pull_request.merged == true
10
10
runs-on : ubuntu-latest
11
11
12
12
steps :
25
25
npm ci
26
26
npm run lerna-ci
27
27
28
- # - name: "Setup npm"
29
- # run: |
30
- # npm set @xcanchal:registry=https://npm.pkg.github.com/xcanchal
31
- # npm set "//npm.pkg.github.com/:_authToken=${{ secrets.GITHUB_TOKEN }}"
28
+ - name : " Setup npm"
29
+ run : |
30
+ npm set "//registry.npmjs.org/:_authToken=${{ secrets.NPM_TOKEN }}"
32
31
33
32
- name : " Version and publish"
34
33
env :
43
42
npx lerna version --conventional-commits --conventional-prerelease --preid beta --create-release github --yes
44
43
fi
45
44
46
- # npx lerna publish from-git --yes
47
-
45
+ npx lerna publish --no-verify-access from-git --yes
46
+
48
47
slack :
49
48
name : Publish to slack channel
50
49
needs :
@@ -53,11 +52,11 @@ jobs:
53
52
steps :
54
53
- name : publish latest release
55
54
env :
56
- SLACK_URL : ${{ secrets.SLACK_URL }}
55
+ SLACK_WEBHOOK_URL : ${{ secrets.SLACK_WEBHOOK_URL }}
57
56
run : |
58
57
curl -H "Accept: application/vnd.github.v3+json" https://api.github.com/repos/${{ github.repository }}/releases/latest > release.json
59
58
VERSION=$( jq -r '.name' release.json )
60
59
CONTENT=$( jq -r '.body' release.json )
61
60
jq -n --arg version "$VERSION" --arg content "$CONTENT" '{"release-version": $version, "release-content": $content}' > body.json
62
- curl --location --request POST $SLACK_URL \
63
- --header 'Content-Type: application/json' --data @body.json
61
+ curl --location --request POST $SLACK_WEBHOOK_URL \
62
+ --header 'Content-Type: application/json' --data @body.json
You can’t perform that action at this time.
0 commit comments