Skip to content

Commit be6d40d

Browse files
committed
revert script changes
1 parent 8368cf3 commit be6d40d

File tree

1 file changed

+4
-7
lines changed

1 file changed

+4
-7
lines changed

.github/workflows/build-and-release.yml

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -116,23 +116,20 @@ jobs:
116116
id: get_pr_data
117117
with:
118118
script: |
119-
const prData = (
119+
return (
120120
await github.rest.repos.listPullRequestsAssociatedWithCommit({
121121
commit_sha: context.sha,
122122
owner: context.repo.owner,
123123
repo: context.repo.repo,
124124
})
125125
).data[0];
126-
core.setOutput("title", prData?.title || "No title");
127-
core.setOutput("body", prData?.body || "No description");
128-
core.setOutput("html_url", prData?.html_url || "No URL");
129126
- name: Discord Webhook Action
130127
uses: tsickert/[email protected]
131128
with:
132129
webhook-url: ${{ secrets.DISCORD_WEBHOOK_URL }}
133130
embed-title: |
134-
🎉 New update on `master` branch: ${{ steps.get_pr_data.outputs.title }}
131+
🎉 New update on `master` branch: ${{ fromJson(steps.get_pr_data.outputs.result).title }}
135132
embed-description: |
136-
${{ steps.get_pr_data.outputs.body }}
137-
embed-url: ${{ steps.get_pr_data.outputs.html_url}}
133+
${{ fromJson(steps.get_pr_data.outputs.result).body }}
134+
embed-url: ${{ fromJson(steps.get_pr_data.outputs.result).html_url }}
138135

0 commit comments

Comments
 (0)