@liangjie559567/ultrapower 5.2.9 → 5.2.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.claude-plugin/plugin.json +1 -1
- package/docs/CLAUDE.md +1 -1
- package/package.json +1 -1
- package/scripts/plugin-setup.mjs +21 -14
- package/scripts/release-steps.mjs +13 -0
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "ultrapower",
|
|
3
3
|
"description": "Disciplined multi-agent orchestration: workflow enforcement + parallel execution. Combines superpowers' TDD/debugging discipline with OMC's multi-agent execution capabilities.",
|
|
4
|
-
"version": "5.2.
|
|
4
|
+
"version": "5.2.9",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "Jesse Vincent & oh-my-claudecode contributors"
|
|
7
7
|
},
|
package/docs/CLAUDE.md
CHANGED
package/package.json
CHANGED
package/scripts/plugin-setup.mjs
CHANGED
|
@@ -20,28 +20,35 @@ const SETTINGS_FILE = join(CLAUDE_DIR, 'settings.json');
|
|
|
20
20
|
console.log('[OMC] Running post-install setup...');
|
|
21
21
|
|
|
22
22
|
// Fix: flatten nested cache directories caused by Claude Code installer bug.
|
|
23
|
-
// Root cause: Claude Code copies npm package contents into cache/
|
|
23
|
+
// Root cause: Claude Code copies npm package contents into cache/omc/, but the package
|
|
24
24
|
// itself contains an 'ultrapower/' subdirectory, causing infinite nesting on each restart.
|
|
25
25
|
// Two known nesting patterns:
|
|
26
|
-
// Pattern A (flat root): cache/
|
|
27
|
-
// Pattern B (versioned): cache/
|
|
26
|
+
// Pattern A (flat root): cache/omc/ultrapower/5.0.23/ultrapower/5.0.23/...
|
|
27
|
+
// Pattern B (versioned): cache/omc/ultrapower/VERSION/ultrapower/VERSION/...
|
|
28
28
|
// This function handles both by detecting and removing the nested 'ultrapower/' subtree
|
|
29
|
-
// directly under cache/
|
|
29
|
+
// directly under cache/omc/ (Pattern A), which is the primary observed pattern.
|
|
30
30
|
function fixNestedCacheDir() {
|
|
31
31
|
try {
|
|
32
|
-
// Pattern A: cache/
|
|
33
|
-
|
|
32
|
+
// Pattern A: cache/omc/ultrapower/ exists but is NOT the legitimate
|
|
33
|
+
// marketplace/plugin path. Only remove if it contains no version dirs
|
|
34
|
+
// and no plugin markers — i.e. it's a stale empty nesting artifact.
|
|
35
|
+
const pluginCacheRoot = join(CLAUDE_DIR, 'plugins/cache/omc');
|
|
34
36
|
const nestedRootDir = join(pluginCacheRoot, 'ultrapower');
|
|
35
37
|
if (existsSync(nestedRootDir)) {
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
38
|
+
const nestedContents = readdirSync(nestedRootDir);
|
|
39
|
+
const PLUGIN_MARKERS = ['skills', 'dist', 'agents', 'hooks'];
|
|
40
|
+
const hasVersionDirs = nestedContents.some(f => /^\d+\.\d+/.test(f));
|
|
41
|
+
const hasPluginMarkers = nestedContents.some(f => PLUGIN_MARKERS.includes(f));
|
|
42
|
+
if (!hasVersionDirs && !hasPluginMarkers) {
|
|
43
|
+
console.log('[OMC] Detected stale nested cache dir at plugins/cache/omc/ultrapower/ — removing...');
|
|
44
|
+
rmSync(nestedRootDir, { recursive: true, force: true });
|
|
45
|
+
console.log('[OMC] Removed stale nested cache dir (Pattern A)');
|
|
46
|
+
}
|
|
39
47
|
}
|
|
40
48
|
|
|
41
|
-
// Pattern B: cache/
|
|
42
|
-
const pluginCacheBase = join(CLAUDE_DIR, 'plugins/cache/
|
|
49
|
+
// Pattern B: cache/omc/ultrapower/VERSION/ (versioned nesting)
|
|
50
|
+
const pluginCacheBase = join(CLAUDE_DIR, 'plugins/cache/omc/ultrapower');
|
|
43
51
|
if (!existsSync(pluginCacheBase)) return;
|
|
44
|
-
const versions = readdirSync(pluginCacheBase);
|
|
45
52
|
for (const version of versions) {
|
|
46
53
|
const versionDir = join(pluginCacheBase, version);
|
|
47
54
|
const nestedDir = join(versionDir, 'ultrapower');
|
|
@@ -103,7 +110,7 @@ fixNestedCacheDir();
|
|
|
103
110
|
// hooks/hooks.json paths (${CLAUDE_PLUGIN_ROOT}/templates/hooks/*.mjs) resolve correctly.
|
|
104
111
|
function copyTemplatesToCache() {
|
|
105
112
|
try {
|
|
106
|
-
const pluginCacheBase = join(CLAUDE_DIR, 'plugins/cache/
|
|
113
|
+
const pluginCacheBase = join(CLAUDE_DIR, 'plugins/cache/omc/ultrapower');
|
|
107
114
|
if (!existsSync(pluginCacheBase)) return;
|
|
108
115
|
|
|
109
116
|
// __dirname = <pkg-root>/scripts/, so dirname(__dirname) = <pkg-root>/
|
|
@@ -199,7 +206,7 @@ function fixMissingPluginJson() {
|
|
|
199
206
|
|
|
200
207
|
// 2. Write directly to plugin cache (marketplace: ultrapower, plugin: ultrapower)
|
|
201
208
|
// Claude Code copies from npm-cache but skips hidden dirs, so we patch the cache directly.
|
|
202
|
-
const pluginCacheBase = join(CLAUDE_DIR, 'plugins/cache/
|
|
209
|
+
const pluginCacheBase = join(CLAUDE_DIR, 'plugins/cache/omc/ultrapower');
|
|
203
210
|
if (existsSync(pluginCacheBase)) {
|
|
204
211
|
const versions = readdirSync(pluginCacheBase);
|
|
205
212
|
for (const v of versions) {
|
|
@@ -55,6 +55,19 @@ export async function syncMarketplace(opts = {}) {
|
|
|
55
55
|
const { version, dryRun = false } = opts;
|
|
56
56
|
const v = version || getVersion();
|
|
57
57
|
try {
|
|
58
|
+
// Update marketplace.json version fields
|
|
59
|
+
const marketplacePath = resolve('.claude-plugin/marketplace.json');
|
|
60
|
+
const marketplace = JSON.parse(readFileSync(marketplacePath, 'utf-8'));
|
|
61
|
+
for (const plugin of marketplace.plugins ?? []) {
|
|
62
|
+
plugin.version = v;
|
|
63
|
+
if (plugin.source) plugin.source.version = v;
|
|
64
|
+
}
|
|
65
|
+
if (!dryRun) {
|
|
66
|
+
const { writeFileSync } = await import('node:fs');
|
|
67
|
+
writeFileSync(marketplacePath, JSON.stringify(marketplace, null, 2) + '\n');
|
|
68
|
+
} else {
|
|
69
|
+
console.log(`[dry-run] Would write marketplace.json version -> ${v}`);
|
|
70
|
+
}
|
|
58
71
|
run(`git add .claude-plugin/marketplace.json`, dryRun);
|
|
59
72
|
run(`git commit -m "chore: sync marketplace version to v${v}" --allow-empty`, dryRun);
|
|
60
73
|
run(`git push origin HEAD`, dryRun);
|