Skip to content

Commit f1589ca

Browse files
committed
feat: uses 2 dots compare syntax for push diff
1 parent 046435d commit f1589ca

File tree

3 files changed

+6
-9
lines changed

3 files changed

+6
-9
lines changed

dist/post_run/index.js

Lines changed: 2 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/run/index.js

Lines changed: 2 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/run.ts

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -104,11 +104,10 @@ async function fetchPushPatch(ctx: Context): Promise<string> {
104104

105105
let patch: string
106106
try {
107-
const patchResp = await octokit.rest.repos.compareCommits({
107+
const patchResp = await octokit.rest.repos.compareCommitsWithBasehead({
108108
owner: ctx.repo.owner,
109109
repo: ctx.repo.repo,
110-
base: ctx.payload.before,
111-
head: ctx.payload.after,
110+
basehead: `${ctx.payload.before}..${ctx.payload.after}`,
112111
mediaType: {
113112
format: `diff`,
114113
},

0 commit comments

Comments
 (0)