From a202b5a1793d2ce1c3a25a11f902a3af06fa2fc0 Mon Sep 17 00:00:00 2001 From: KeyInfo Bot Date: Mon, 27 Jul 2026 11:14:36 +0800 Subject: [PATCH] Sync third-party and MCP marketplace plugins Constraint: Public skills are published only by explicit administrator action unless they are tracked third-party market sources. Confidence: high Scope-risk: narrow Directive: Keep private/internal skills out of the public marketplace and preserve normal incremental market Git history. Tested: Marketplace validation passed. --- config/external-sources.json | 4 +++ .../plugins/mcp-playwright/MCP_SOURCE.json | 2 +- scripts/sync_external_plugins.ps1 | 32 ++++++++++++++----- 3 files changed, 29 insertions(+), 9 deletions(-) diff --git a/config/external-sources.json b/config/external-sources.json index 941873a8..abd94354 100644 --- a/config/external-sources.json +++ b/config/external-sources.json @@ -279,6 +279,10 @@ "pluginName": "shadcn", "category": "Developer Tools", "skillPath": "skills/shadcn", + "sparseCheckout": [ + "skills/shadcn", + "LICENSE.md" + ], "brandColor": "#09090B", "manifestOverrides": { "version": "0.1.0", diff --git a/plugins/codex/plugins/mcp-playwright/MCP_SOURCE.json b/plugins/codex/plugins/mcp-playwright/MCP_SOURCE.json index 645dab56..c147673b 100644 --- a/plugins/codex/plugins/mcp-playwright/MCP_SOURCE.json +++ b/plugins/codex/plugins/mcp-playwright/MCP_SOURCE.json @@ -3,5 +3,5 @@ "name": "playwright浏览器自动化操作", "version": "20260605", "keySource": "none", - "syncedAt": "2026-07-27T03:12:39Z" + "syncedAt": "2026-07-27T03:14:35Z" } diff --git a/scripts/sync_external_plugins.ps1 b/scripts/sync_external_plugins.ps1 index 1168fccc..f735f836 100644 --- a/scripts/sync_external_plugins.ps1 +++ b/scripts/sync_external_plugins.ps1 @@ -627,14 +627,30 @@ function Get-Clone { $sparseCheckout = @($Source.sparseCheckout) } $cloneArgs += @($Source.repo, $clonePath) - Invoke-CheckedGit $cloneArgs - if ($Source.ref) { - Invoke-CheckedGit @("-C", $clonePath, "fetch", "--depth", "1", "origin", $Source.ref) - Invoke-CheckedGit @("-C", $clonePath, "checkout", "FETCH_HEAD") - } - if ($sparseCheckout.Count -gt 0) { - $sparseArgs = @("-C", $clonePath, "sparse-checkout", "set", "--no-cone") + $sparseCheckout - Invoke-CheckedGit $sparseArgs + $maxAttempts = 3 + for ($attempt = 1; $attempt -le $maxAttempts; $attempt++) { + Remove-PathIfExists -Path $clonePath -Within $CloneRoot + $transportArgs = @() + if ($attempt -gt 1) { + $transportArgs = @("-c", "http.version=HTTP/1.1") + } + try { + Invoke-CheckedGit -GitArgs ($transportArgs + $cloneArgs) + if ($Source.ref) { + Invoke-CheckedGit -GitArgs ($transportArgs + @("-C", $clonePath, "fetch", "--depth", "1", "origin", $Source.ref)) + Invoke-CheckedGit -GitArgs @("-C", $clonePath, "checkout", "FETCH_HEAD") + } + if ($sparseCheckout.Count -gt 0) { + $sparseArgs = @("-C", $clonePath, "sparse-checkout", "set", "--no-cone") + $sparseCheckout + Invoke-CheckedGit -GitArgs $sparseArgs + } + break + } catch { + if ($attempt -eq $maxAttempts) { + throw "Third-party source $($Source.id) clone failed after $maxAttempts attempts: $($_.Exception.Message)" + } + Start-Sleep -Seconds ([Math]::Pow(2, $attempt - 1)) + } } $commit = (git -C $clonePath rev-parse HEAD).Trim() return [ordered]@{