Pulumi code for my server setup
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

replace fetch with gh CLI for tags as well

+2 -10
+2 -10
lib/util.ts
··· 19 19 .min(1); 20 20 21 21 export async function getLatestGithubTag(repo: string) { 22 - const githubApiToken = await $`gh auth token`.text(); 23 - const githubApi = ky.create({ 24 - headers: { 25 - Authorization: `Bearer ${githubApiToken}`, 26 - }, 27 - retry: 5, 28 - }); 29 - 30 - const url = `https://api.github.com/repos/${repo}/tags`; 31 - const json = await githubApi(url, { retry: 5 }).json(GithubReleaseSchema); 22 + const output = await $`gh api repos/${repo}/tags`.json(); 23 + const json = GithubReleaseSchema.parse(output); 32 24 assert(json[0]); 33 25 return json[0].name; 34 26 }