MCPcopy Create free account
hub / github.com/CodeGraphContext/CodeGraphContext / getPublicZipUrl

Function getPublicZipUrl

website/src/lib/repo-provider.ts:218–223  ·  view source on GitHub ↗
(ref: RepoRef, branch: string)

Source from the content-addressed store, hash-verified

216}
217
218export function getPublicZipUrl(ref: RepoRef, branch: string): string {
219 if (ref.provider === "gitlab") {
220 return `https://gitlab.com/${ref.fullPath}/-/archive/${branch}/${ref.repo}-${branch}.zip`;
221 }
222 return `https://github.com/${ref.owner}/${ref.repo}/archive/refs/heads/${branch}.zip`;
223}
224
225export function getAuthenticatedZipUrl(ref: RepoRef, branch: string): string | null {
226 const token = localStorage.getItem(getAuthTokenKey(ref));

Callers 1

fetchRepositoryFilesFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected