({ owner, repo }: { owner: string; repo: string })
| 66 | } |
| 67 | |
| 68 | export const getRepoSHA = async ({ owner, repo }: { owner: string; repo: string }) => { |
| 69 | const octokit = getOctokit() |
| 70 | const commits = await octokit.request('GET /repos/{owner}/{repo}/commits?per_page=1&page=1', { |
| 71 | owner, |
| 72 | repo |
| 73 | }) |
| 74 | return commits.data?.[0]?.sha |
| 75 | } |
| 76 | |
| 77 | // Web hooks |
| 78 |
no test coverage detected