fix: support concurrent game windows and prepare beta12 GitHub releases
This commit is contained in:
1 parent
91f483b960
commit
1cf67602d8
33 files changed
+681
-293
No files matched your search
@@ -2,6 +2,8 @@ import fs from 'node:fs'
|
||||
|
||||
const [manifestPath, tag, source = 'github'] = process.argv.slice(2)
|
||||
const expectedVersion = tag?.replace(/^v/, '')
|
||||
const githubRepository = process.env.GITHUB_REPOSITORY || 'ApTx2012/Starlight_Lancher'
|
||||
const cnbRepository = process.env.CNB_REPO_SLUG || 'axlmc/Axolotl'
|
||||
|
||||
if (!manifestPath || !expectedVersion || !['github', 'cnb'].includes(source)) {
|
||||
throw new Error('Usage: node verify-update-manifest.mjs <latest.json> <version-tag> [github|cnb]')
|
||||
@@ -34,9 +36,13 @@ for (const platform of requiredPlatforms) {
|
||||
url.protocol === 'https:' &&
|
||||
(source === 'github'
|
||||
? url.hostname === 'github.com' &&
|
||||
pathname.includes('/mystic-stars/axolotl/releases/download/')
|
||||
pathname.startsWith(
|
||||
`/${githubRepository.toLowerCase()}/releases/download/${tag.toLowerCase()}/`,
|
||||
)
|
||||
: url.hostname === 'cnb.cool' &&
|
||||
pathname.includes(`/axlmc/axolotl/-/releases/download/${tag.toLowerCase()}/`))
|
||||
pathname.startsWith(
|
||||
`/${cnbRepository.toLowerCase()}/-/releases/download/${tag.toLowerCase()}/`,
|
||||
))
|
||||
if (!isExpectedUrl) {
|
||||
throw new Error(`Unexpected ${source} update URL for ${platform}: ${update.url}`)
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user