(ref: RepoRef, branch: string, filePath: string)
| 246 | } |
| 247 | |
| 248 | export function getCdnFileUrl(ref: RepoRef, branch: string, filePath: string): string | null { |
| 249 | if (ref.provider === "github") { |
| 250 | return `https://cdn.jsdelivr.net/gh/${ref.owner}/${ref.repo}@${branch}/${filePath}`; |
| 251 | } |
| 252 | return null; |
| 253 | } |
| 254 | |
| 255 | /** List all file paths in a repository (fallback when ZIP download fails). */ |
| 256 | export async function listRepositoryFiles( |
no outgoing calls
no test coverage detected