Skip to content

Commit

Permalink
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions scripts/changelog/generate-changelog.ts
Original file line number Diff line number Diff line change
@@ -14,7 +14,7 @@ const getFilePath = (p: string) => path.resolve(ROOT_DIR, p)
const FEAT_N_FIX_HEADER = `### 🚀 Features & Fixes`
const CONTRIB_HEADER = `### 🙌 Contributions`

const MAINTAINER_LOGINS = ['octref', 'orta']
const MAINTAINER_LOGINS = ['octref', 'orta', 'antfu']

const readQuery = (filename: string) => {
return fs.readFileSync(path.resolve(__dirname, `./${filename}`), 'utf-8')
@@ -29,11 +29,14 @@ const getGithubGraphql = async (query: string) => {
headers: {
'Content-Type': 'application/json',
'Content-Length': `${data.length}`,
Authorization: 'bearer ' + process.env.GITHUB_SECRET,
Authorization: 'bearer ' + (process.env.GITHUB_SECRET || process.env.GITHUB_TOKEN),
'User-Agent': 'Shiki'
}
})

if (200 < res.status && res.status >= 300)
throw new Error(`Failed to fetch: ${res.status} ${res.statusText}`)

return await res.json()
}

0 comments on commit 65d8151

Please sign in to comment.