fix(ci): parallelize npm publish to prevent OIDC token expiration

- Publish platform packages in parallel using Promise.all()
- Update README versions to beta.10 (EN, JA, ZH-CN)
This commit is contained in:
justsisyphus
2026-01-18 13:12:08 +09:00
parent 31dfef85b8
commit 6a4bac9478
4 changed files with 22 additions and 11 deletions

View File

@@ -5,8 +5,8 @@
> [!TIP]
>
> [![The Orchestrator is now available in beta.](./.github/assets/orchestrator-sisyphus.png?v=3)](https://github.com/code-yeongyu/oh-my-opencode/releases/tag/v3.0.0-beta.1)
> > **オーケストレーターがベータ版で利用可能になりました。`oh-my-opencode@3.0.0-beta.1`を使用してインストールしてください。**
> [![The Orchestrator is now available in beta.](./.github/assets/orchestrator-sisyphus.png?v=3)](https://github.com/code-yeongyu/oh-my-opencode/releases/tag/v3.0.0-beta.10)
> > **オーケストレーターがベータ版で利用可能になりました。`oh-my-opencode@3.0.0-beta.10`を使用してインストールしてください。**
>
> 一緒に歩みましょう!
>

View File

@@ -5,8 +5,8 @@
> [!TIP]
>
> [![The Orchestrator is now available in beta.](./.github/assets/orchestrator-sisyphus.png?v=3)](https://github.com/code-yeongyu/oh-my-opencode/releases/tag/v3.0.0-beta.7)
> > **The Orchestrator is now available in beta. Use `oh-my-opencode@3.0.0-beta.7` to install it.**
> [![The Orchestrator is now available in beta.](./.github/assets/orchestrator-sisyphus.png?v=3)](https://github.com/code-yeongyu/oh-my-opencode/releases/tag/v3.0.0-beta.10)
> > **The Orchestrator is now available in beta. Use `oh-my-opencode@3.0.0-beta.10` to install it.**
>
> Be with us!
>

View File

@@ -5,8 +5,8 @@
> [!TIP]
>
> [![Orchestrator 现已进入测试阶段。](./.github/assets/orchestrator-sisyphus.png?v=3)](https://github.com/code-yeongyu/oh-my-opencode/releases/tag/v3.0.0-beta.1)
> > **Orchestrator 现已进入测试阶段。使用 `oh-my-opencode@3.0.0-beta.1` 安装。**
> [![Orchestrator 现已进入测试阶段。](./.github/assets/orchestrator-sisyphus.png?v=3)](https://github.com/code-yeongyu/oh-my-opencode/releases/tag/v3.0.0-beta.10)
> > **Orchestrator 现已进入测试阶段。使用 `oh-my-opencode@3.0.0-beta.10` 安装。**
>
> 加入我们!
>

View File

@@ -192,16 +192,23 @@ async function publishAllPackages(version: string): Promise<void> {
if (skipPlatform) {
console.log("\n⏭ Skipping platform packages (SKIP_PLATFORM_PACKAGES=true)")
} else {
console.log("\n📦 Publishing platform packages...")
console.log("\n📦 Publishing platform packages in parallel...")
// Publish platform packages first
for (const platform of PLATFORM_PACKAGES) {
// Publish platform packages in parallel for speed (avoids OIDC token expiration)
const publishPromises = PLATFORM_PACKAGES.map(async (platform) => {
const pkgDir = join(process.cwd(), "packages", platform)
const pkgName = `oh-my-opencode-${platform}`
console.log(`\n Publishing ${pkgName}...`)
console.log(` Starting ${pkgName}...`)
const result = await publishPackage(pkgDir, distTag)
return { platform, pkgName, result }
})
const results = await Promise.all(publishPromises)
const failures: string[] = []
for (const { pkgName, result } of results) {
if (result.success) {
if (result.alreadyPublished) {
console.log(`${pkgName}@${version} (already published)`)
@@ -210,9 +217,13 @@ async function publishAllPackages(version: string): Promise<void> {
}
} else {
console.error(`${pkgName} failed: ${result.error}`)
throw new Error(`Failed to publish ${pkgName}`)
failures.push(pkgName)
}
}
if (failures.length > 0) {
throw new Error(`Failed to publish: ${failures.join(", ")}`)
}
}
// Publish main package last