File tree 3 files changed +22
-20
lines changed
3 files changed +22
-20
lines changed Original file line number Diff line number Diff line change 22
22
needs : [authorize]
23
23
uses : storyprotocol/gha-workflows/.github/workflows/reusable-timestamp.yml@main
24
24
25
- pr_build_and_test :
25
+ unit_tests :
26
26
needs : [authorize, Timestamp_PR_APPROVED]
27
27
uses : storyprotocol/gha-workflows/.github/workflows/reusable-build-unit-test-workflow.yml@main
28
28
with :
32
32
WALLET_PRIVATE_KEY : ${{ secrets.WALLET_PRIVATE_KEY }}
33
33
TEST_WALLET_ADDRESS : ${{ secrets.TEST_WALLET_ADDRESS }}
34
34
35
- push_build_and_test :
36
- needs : [pr_build_and_test ]
35
+ integration_tests :
36
+ needs : [unit_tests ]
37
37
uses : storyprotocol/gha-workflows/.github/workflows/reusable-build-integration-test-workflow.yml@main
38
38
with :
39
39
sha : ${{ github.event.pull_request.head.sha }}
Original file line number Diff line number Diff line change @@ -13,22 +13,22 @@ jobs:
13
13
if : ${{ github.event.pull_request.head.repo.full_name == github.repository }}
14
14
uses : storyprotocol/gha-workflows/.github/workflows/reusable-timestamp.yml@main
15
15
16
- pr_build_and_test :
17
- if : github.event_name == 'pull_request'
16
+ unit_tests :
18
17
needs : [Timestamp]
19
18
uses : storyprotocol/gha-workflows/.github/workflows/reusable-build-unit-test-workflow.yml@main
20
19
with :
21
- sha : ${{ github.event.pull_request.head.sha }}
20
+ sha : ${{ github.event_name == 'pull_request' && github. event.pull_request.head.sha || github .sha }}
22
21
ENVIRONMENT : " odyssey"
23
22
secrets :
24
23
WALLET_PRIVATE_KEY : ${{ secrets.WALLET_PRIVATE_KEY }}
25
24
TEST_WALLET_ADDRESS : ${{ secrets.TEST_WALLET_ADDRESS }}
26
25
27
- push_build_and_test :
28
- if : github.event_name == 'push'
26
+ integration_tests :
27
+ if : github.event_name == 'pull_request'
28
+ needs : [Timestamp]
29
29
uses : storyprotocol/gha-workflows/.github/workflows/reusable-build-integration-test-workflow.yml@main
30
30
with :
31
- sha : ${{ github.sha }}
31
+ sha : ${{ github.event.pull_request.head. sha }}
32
32
ENVIRONMENT : " odyssey"
33
33
secrets :
34
34
WALLET_PRIVATE_KEY : ${{ secrets.WALLET_PRIVATE_KEY }}
Original file line number Diff line number Diff line change @@ -119,15 +119,17 @@ jobs:
119
119
npm publish
120
120
env :
121
121
NODE_AUTH_TOKEN : ${{ secrets.NPM_TOKEN }}
122
-
122
+
123
123
send_slack_notif-core-sdk :
124
- needs : [print_version_to_publish]
125
- uses : storyprotocol/gha-workflows/.github/workflows/reusable-slack-notifs.yml@main
126
- with :
127
- short-desc : " ${{ github.repository }}: @story-protocol/core-sdk package has been published to NPM Registry, version: ${{ needs.print_version_to_publish.outputs.CORE_SDK_VERSION_TO_BE_PUBLISHED}}"
128
- title : " Published to Registry"
129
- img-url : " https://i.imgur.com/JHmKB0s.png"
130
- img-alt-text : " Published to Registry"
131
- secrets :
132
- channel-name : ${{ secrets.SLACK_CHANNEL_ID_STORY_57BLOCKS }}
133
- slack-bot-token : ${{ secrets.SLACK_BOT_TOKEN }}
124
+ runs-on : ubuntu-latest
125
+ environment : " odyssey"
126
+ steps :
127
+ - name : Send Slack Notification
128
+ run : |
129
+ curl -X POST \
130
+ -H 'Content-type: application/json' \
131
+ --data '{
132
+ "channel": "proj-sdk",
133
+ "text":"${{ github.repository }}: @story-protocol/core-sdk package has been published to NPM Registry, version: ${{ needs.print_version_to_publish.outputs.CORE_SDK_VERSION_TO_BE_PUBLISHED}}"
134
+ }' \
135
+ ${{ secrets.SLACK_SDK_MESSENGER_WEBHOOK_URL }}
You can’t perform that action at this time.
0 commit comments