gm-skill 2.0.1285 → 2.0.1286
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/README.md +1 -1
- package/bin/bootstrap.js +48 -0
- package/gm.json +1 -1
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -35,7 +35,7 @@ An earlier generation fanned out fifteen per-platform downstream repos (gm-cc, g
|
|
|
35
35
|
|
|
36
36
|
## Version
|
|
37
37
|
|
|
38
|
-
`2.0.
|
|
38
|
+
`2.0.1286` — auto-bumped from the canonical `gm` repo. Every push to `AnEntrypoint/gm` (or any cascading sibling crate) republishes this package.
|
|
39
39
|
|
|
40
40
|
## Source of truth
|
|
41
41
|
|
package/bin/bootstrap.js
CHANGED
|
@@ -17,6 +17,53 @@ function log(msg) {
|
|
|
17
17
|
try { process.stderr.write(`[plugkit-bootstrap] ${msg}\n`); } catch (_) {}
|
|
18
18
|
}
|
|
19
19
|
|
|
20
|
+
function ensureSkillMdCurrent(wrapperDir) {
|
|
21
|
+
try {
|
|
22
|
+
const candidates = [
|
|
23
|
+
path.join(wrapperDir, '..', 'skills', 'gm-skill', 'SKILL.md'),
|
|
24
|
+
path.join(wrapperDir, '..', '..', 'skills', 'gm-skill', 'SKILL.md'),
|
|
25
|
+
path.join(wrapperDir, '..', 'SKILL.md'),
|
|
26
|
+
];
|
|
27
|
+
const bundledPath = candidates.find(p => { try { return fs.existsSync(p); } catch (_) { return false; } });
|
|
28
|
+
if (!bundledPath) return { skipped: 'bundled-not-found' };
|
|
29
|
+
const bundled = fs.readFileSync(bundledPath, 'utf8');
|
|
30
|
+
const bundledHash = crypto.createHash('sha256').update(bundled).digest('hex');
|
|
31
|
+
const home = os.homedir();
|
|
32
|
+
const targets = [
|
|
33
|
+
path.join(home, '.agents', 'skills', 'gm-skill', 'SKILL.md'),
|
|
34
|
+
path.join(home, '.claude', 'skills', 'gm-skill', 'SKILL.md'),
|
|
35
|
+
];
|
|
36
|
+
const refreshed = [];
|
|
37
|
+
for (const target of targets) {
|
|
38
|
+
try {
|
|
39
|
+
let needsWrite = true;
|
|
40
|
+
if (fs.existsSync(target)) {
|
|
41
|
+
const existing = fs.readFileSync(target, 'utf8');
|
|
42
|
+
const existingHash = crypto.createHash('sha256').update(existing).digest('hex');
|
|
43
|
+
if (existingHash === bundledHash) needsWrite = false;
|
|
44
|
+
}
|
|
45
|
+
if (needsWrite) {
|
|
46
|
+
fs.mkdirSync(path.dirname(target), { recursive: true });
|
|
47
|
+
const tmp = target + '.tmp';
|
|
48
|
+
fs.writeFileSync(tmp, bundled);
|
|
49
|
+
fs.renameSync(tmp, target);
|
|
50
|
+
refreshed.push(target);
|
|
51
|
+
}
|
|
52
|
+
} catch (e) {
|
|
53
|
+
obsEvent('bootstrap', 'skill-md.refresh.target-failed', { target, error: e.message });
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
if (refreshed.length > 0) {
|
|
57
|
+
log(`SKILL.md refreshed (sha=${bundledHash.slice(0, 12)}): ${refreshed.join(', ')}`);
|
|
58
|
+
obsEvent('bootstrap', 'skill-md.refreshed', { hash: bundledHash.slice(0, 12), targets: refreshed });
|
|
59
|
+
}
|
|
60
|
+
return { refreshed, bundledHash };
|
|
61
|
+
} catch (e) {
|
|
62
|
+
obsEvent('bootstrap', 'skill-md.refresh.failed', { error: e.message });
|
|
63
|
+
return { error: e.message };
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
|
|
20
67
|
// Resolve a bare command name to its actual .exe on Windows. cmd.exe + .cmd
|
|
21
68
|
// shim chains re-enter conhost (visible window flash) even with
|
|
22
69
|
// windowsHide:true on the parent. Spawning the real .exe directly lets
|
|
@@ -355,6 +402,7 @@ function pruneOldVersions(root, keepVersion, keepRtkVersion) {
|
|
|
355
402
|
async function bootstrap(opts) {
|
|
356
403
|
opts = opts || {};
|
|
357
404
|
const wrapperDir = opts.wrapperDir || __dirname;
|
|
405
|
+
try { ensureSkillMdCurrent(wrapperDir); } catch (_) {}
|
|
358
406
|
const version = opts.version || readVersionFile(wrapperDir);
|
|
359
407
|
const shaManifest = readShaManifest(wrapperDir);
|
|
360
408
|
const wasmName = 'plugkit.wasm';
|
package/gm.json
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "gm-skill",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.1286",
|
|
4
4
|
"description": "Canonical universal harness — AI-native software engineering via skill-driven orchestration; bootstraps plugkit for task execution and session isolation. Install in any AI coding agent host.",
|
|
5
5
|
"author": "AnEntrypoint",
|
|
6
6
|
"license": "MIT",
|
|
@@ -39,7 +39,7 @@
|
|
|
39
39
|
"gm.json"
|
|
40
40
|
],
|
|
41
41
|
"dependencies": {
|
|
42
|
-
"gm-plugkit": "^2.0.
|
|
42
|
+
"gm-plugkit": "^2.0.1286"
|
|
43
43
|
},
|
|
44
44
|
"engines": {
|
|
45
45
|
"node": ">=16.0.0"
|