feat: add read-only GitHub App access alongside OAuth

This commit is contained in:
Thomas Durieux
2026-09-09 22:08:12 +02:00
parent e5c44845f0
commit a60ad6a921
49 changed files with 1754 additions and 139 deletions
+6 -5
View File
@@ -376,11 +376,12 @@ export async function getRepositoryFromGitHub(opt: {
| RestEndpointMethodTypes["repos"]["getPages"]["response"]["data"]["source"]
| undefined;
if (r.has_pages) {
const ghPageRes = await oct.repos.getPages({
owner: opt.owner,
repo: opt.repo,
});
pageSource = ghPageRes.data.source;
try {
const ghPageRes = await oct.repos.getPages({ owner: opt.owner, repo: opt.repo });
pageSource = ghPageRes.data.source;
} catch (error) {
if (![403, 404].includes((error as { status?: number }).status || 0)) throw error;
}
}
if (!isConnected) {