From 94fcda59a064b5e8952d1bccb6b9a153c39acda1 Mon Sep 17 00:00:00 2001 From: Joe Mou Date: Wed, 28 Jan 2026 22:41:00 -0500 Subject: Commits list --- cgithub/src/index.ts | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'cgithub/src/index.ts') diff --git a/cgithub/src/index.ts b/cgithub/src/index.ts index d4229fd..4486dff 100644 --- a/cgithub/src/index.ts +++ b/cgithub/src/index.ts @@ -7,6 +7,7 @@ import path from "node:path"; import url from "node:url"; import { getGitHubBlob, + getGitHubCommits, getGitHubIssues, getGitHubRepo, getGitHubTree, @@ -67,6 +68,11 @@ app.get("/:owner/:repo/issues", async (c) => { return tryRender(c, "issues.eta", getGitHubIssues(owner, repo)); }); +app.get("/:owner/:repo/commits/:branch/:path{.*}?", async (c) => { + const { owner, repo, branch, path = "" } = c.req.param(); + return tryRender(c, "commits.eta", getGitHubCommits(owner, repo, branch, path)); +}); + app.all("*", async (c) => { const path = c.req.path; c.header("Referrer-Policy", "no-referrer"); -- cgit v1.3.1