(raw: string)
| 106 | } |
| 107 | |
| 108 | function link(raw: string) { |
| 109 | if (raw.startsWith("https://") || raw.startsWith("http://")) return raw |
| 110 | return `https://github.com/${repo}/releases/download/v${version}/${raw}` |
| 111 | } |
| 112 | |
| 113 | async function sign(url: string, key: string) { |
| 114 | const name = decodeURIComponent(new URL(url).pathname.split("/").pop() ?? key) |