@cohesivity/init 0.3.3 → 0.3.5
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/bin/cli.js +9 -3
- package/package.json +1 -1
package/bin/cli.js
CHANGED
|
@@ -34,7 +34,7 @@ const flag = (f) => { const i = argv.indexOf(f); return i >= 0 ? argv[i + 1] : u
|
|
|
34
34
|
if (has('--help') || has('-h')) { help(); process.exit(0); }
|
|
35
35
|
|
|
36
36
|
// ── config ──────────────────────────────────────────────────────────────────
|
|
37
|
-
const PKG_VERSION = '0.3.
|
|
37
|
+
const PKG_VERSION = '0.3.5';
|
|
38
38
|
const BASE = (flag('--base') || process.env.COHESIVITY_BASE || 'https://cohesivity.ai').replace(/\/+$/, '');
|
|
39
39
|
|
|
40
40
|
// Machine id: one per machine, stored outside any project. A project's
|
|
@@ -50,7 +50,7 @@ const MACHINE_ID_FILE = join(MACHINE_ID_DIR, 'machine-id');
|
|
|
50
50
|
|
|
51
51
|
// The skill is pinned to an immutable commit in the public, auditable repo.
|
|
52
52
|
// Bumping the pin is a deliberate release step. See COH-172.
|
|
53
|
-
const SKILL_PIN = '
|
|
53
|
+
const SKILL_PIN = '6c4c04d94d344590f6732763f0116b155a32753c';
|
|
54
54
|
const SKILL_URL = `https://raw.githubusercontent.com/cohesivity-org/cohesivity-skill/${SKILL_PIN}/cohesivity.skill.md`;
|
|
55
55
|
|
|
56
56
|
// Harness: the nearest ancestor process that is not generic plumbing. Only
|
|
@@ -65,7 +65,13 @@ const GENERIC = new Set('cli index main app run dist build bin lib libexec src o
|
|
|
65
65
|
|
|
66
66
|
function inferHarness() {
|
|
67
67
|
let pid = process.ppid;
|
|
68
|
-
|
|
68
|
+
// `pid >= 1`, not `pid > 1`: pid 1 must be EXAMINED, not merely used as the
|
|
69
|
+
// stop condition. On a normal machine pid 1 is init/systemd and the denylist
|
|
70
|
+
// rejects it anyway, but inside a microVM sandbox pid 1 IS the supervising
|
|
71
|
+
// harness — Claude web runs `/process_api --firecracker-init` there and
|
|
72
|
+
// spawns each command directly from it, so skipping pid 1 made every such
|
|
73
|
+
// sandbox report "none". Pid 1 reports parent 0, so the walk still ends.
|
|
74
|
+
for (let i = 0; i < 20 && pid >= 1; i++) {
|
|
69
75
|
let argv, ppid;
|
|
70
76
|
try {
|
|
71
77
|
argv = readFileSync(`/proc/${pid}/cmdline`, 'utf8').split('\0').filter(Boolean);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cohesivity/init",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.5",
|
|
4
4
|
"description": "Set up Cohesivity in a project: install the agent skill, create a managed backend tenant, write the project config. Run with `npx @cohesivity/init`.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|