@liangjie559567/ultrapower 5.0.14 → 5.0.16
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.
|
@@ -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.0.
|
|
4
|
+
"version": "5.0.16",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "Jesse Vincent & oh-my-claudecode contributors"
|
|
7
7
|
},
|
package/package.json
CHANGED
package/scripts/plugin-setup.mjs
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* Configures HUD statusline when plugin is installed.
|
|
6
6
|
*/
|
|
7
7
|
|
|
8
|
-
import { existsSync, mkdirSync, writeFileSync, readFileSync, readdirSync, chmodSync } from 'node:fs';
|
|
8
|
+
import { existsSync, mkdirSync, writeFileSync, readFileSync, readdirSync, chmodSync, renameSync, rmSync, cpSync } from 'node:fs';
|
|
9
9
|
import { homedir } from 'node:os';
|
|
10
10
|
import { join, dirname } from 'node:path';
|
|
11
11
|
import { fileURLToPath, pathToFileURL } from 'node:url';
|
|
@@ -19,6 +19,41 @@ const SETTINGS_FILE = join(CLAUDE_DIR, 'settings.json');
|
|
|
19
19
|
|
|
20
20
|
console.log('[OMC] Running post-install setup...');
|
|
21
21
|
|
|
22
|
+
// Fix: flatten nested cache directories caused by installer wrapping content in plugin-name subdir.
|
|
23
|
+
// The installer places npm package contents under cache/.../VERSION/ultrapower/ instead of cache/.../VERSION/
|
|
24
|
+
// This function detects and fixes that by moving contents up one level.
|
|
25
|
+
function fixNestedCacheDir() {
|
|
26
|
+
try {
|
|
27
|
+
const pluginCacheBase = join(CLAUDE_DIR, 'plugins/cache/ultrapower/ultrapower');
|
|
28
|
+
if (!existsSync(pluginCacheBase)) return;
|
|
29
|
+
const versions = readdirSync(pluginCacheBase);
|
|
30
|
+
for (const version of versions) {
|
|
31
|
+
const versionDir = join(pluginCacheBase, version);
|
|
32
|
+
const nestedDir = join(versionDir, 'ultrapower');
|
|
33
|
+
if (!existsSync(nestedDir)) continue;
|
|
34
|
+
// Check if the nested dir itself has the actual plugin content (skills/, dist/, etc.)
|
|
35
|
+
const nestedContents = readdirSync(nestedDir);
|
|
36
|
+
const hasPluginContent = nestedContents.some(f => ['skills', 'dist', 'agents', 'hooks'].includes(f));
|
|
37
|
+
if (!hasPluginContent) continue;
|
|
38
|
+
console.log(`[OMC] Fixing nested cache dir for version ${version}...`);
|
|
39
|
+
// Move contents of nestedDir up to versionDir, then remove nestedDir
|
|
40
|
+
for (const item of nestedContents) {
|
|
41
|
+
const src = join(nestedDir, item);
|
|
42
|
+
const dest = join(versionDir, item);
|
|
43
|
+
if (!existsSync(dest)) {
|
|
44
|
+
renameSync(src, dest);
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
rmSync(nestedDir, { recursive: true, force: true });
|
|
48
|
+
console.log(`[OMC] Fixed nested cache dir for version ${version}`);
|
|
49
|
+
}
|
|
50
|
+
} catch (e) {
|
|
51
|
+
console.log('[OMC] Warning: Could not fix nested cache dir:', e.message);
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
fixNestedCacheDir();
|
|
56
|
+
|
|
22
57
|
// 1. Create HUD directory
|
|
23
58
|
if (!existsSync(HUD_DIR)) {
|
|
24
59
|
mkdirSync(HUD_DIR, { recursive: true });
|