Skip to content

Commit 62e000d

Browse files
committed
ci: finalize automatic NPM install testing after release
1 parent 7a7b55f commit 62e000d

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

.github/workflows/npm.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,5 +26,5 @@ jobs:
2626
run: npm install -g @react-native-community/cli
2727
- name: Init new project
2828
run: react-native init --npm test; cd test
29-
- name: Install @next
29+
- name: "Install version ${{ github.event.inputs.version }}"
3030
run: "npm install react-native-render-html@${{ github.event.inputs.version }}"

packages/render-html/scripts/post-release.sh

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,12 +44,13 @@ execGit() {
4444
}
4545

4646
runGithubActions() {
47+
# https://docs.github.com/en/rest/reference/actions#create-a-workflow-dispatch-event
4748
curl \
4849
-X POST \
4950
-H "Accept: application/vnd.github.v3+json" \
5051
-H "authorization: Bearer $GITHUB_TOKEN" \
51-
https://api.github.com/repos/meliorence/react-native-render-html/dispatches \
52-
-d '{"event_type":"workflow_dispatch","inputs":{"version":"'"${version}"'},"workflow":".github/workflows/npm.yml"}'
52+
https://api.github.com/repos/meliorence/react-native-render-html/actions/workflows/npm.yml/dispatches \
53+
-d '{"ref":"master","inputs":{"version":"'"${version}"'"}}'
5354
}
5455

5556
# echo 0 if $1 == $2, 1 if $1 > $2, -1 if $1 < $2

0 commit comments

Comments
 (0)