@clawtrail/init 2.6.0 → 2.7.0
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/dist/index.js +42 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -123,6 +123,7 @@ async function installContextGraph(staging, agentId, apiKey) {
|
|
|
123
123
|
agentId: agentId || void 0,
|
|
124
124
|
apiKey: apiKey || void 0,
|
|
125
125
|
autoSubmit: true,
|
|
126
|
+
detectHttp: true,
|
|
126
127
|
environment: staging ? "staging" : "production"
|
|
127
128
|
}
|
|
128
129
|
};
|
|
@@ -156,6 +157,46 @@ async function installContextGraph(staging, agentId, apiKey) {
|
|
|
156
157
|
);
|
|
157
158
|
packagesInstalled = true;
|
|
158
159
|
installError = "";
|
|
160
|
+
const pkgRoot = path.join(
|
|
161
|
+
extensionsDir,
|
|
162
|
+
"node_modules",
|
|
163
|
+
"@clawtrail",
|
|
164
|
+
"context-graph-openclaw"
|
|
165
|
+
);
|
|
166
|
+
const manifestSrc = path.join(pkgRoot, "openclaw.plugin.json");
|
|
167
|
+
const skillsSrc = path.join(pkgRoot, "skills");
|
|
168
|
+
try {
|
|
169
|
+
await fs.copyFile(
|
|
170
|
+
manifestSrc,
|
|
171
|
+
path.join(extensionsDir, "openclaw.plugin.json")
|
|
172
|
+
);
|
|
173
|
+
} catch {
|
|
174
|
+
}
|
|
175
|
+
try {
|
|
176
|
+
await fs.cp(skillsSrc, path.join(extensionsDir, "skills"), {
|
|
177
|
+
recursive: true
|
|
178
|
+
});
|
|
179
|
+
} catch {
|
|
180
|
+
}
|
|
181
|
+
const rootPkg = {
|
|
182
|
+
name: "context-graph",
|
|
183
|
+
private: true,
|
|
184
|
+
type: "module",
|
|
185
|
+
openclaw: {
|
|
186
|
+
extensions: [
|
|
187
|
+
"./node_modules/@clawtrail/context-graph-openclaw/dist/register.js"
|
|
188
|
+
]
|
|
189
|
+
},
|
|
190
|
+
dependencies: {
|
|
191
|
+
"@clawtrail/context-graph": "^0.1.0",
|
|
192
|
+
"@clawtrail/context-graph-openclaw": "^0.4.0"
|
|
193
|
+
}
|
|
194
|
+
};
|
|
195
|
+
await fs.writeFile(
|
|
196
|
+
path.join(extensionsDir, "package.json"),
|
|
197
|
+
JSON.stringify(rootPkg, null, 2),
|
|
198
|
+
"utf-8"
|
|
199
|
+
);
|
|
159
200
|
} catch (err) {
|
|
160
201
|
const localErr = err.stderr?.toString().trim() || err.stdout?.toString().trim() || err.message || "Unknown error";
|
|
161
202
|
try {
|
|
@@ -516,7 +557,7 @@ async function main() {
|
|
|
516
557
|
const program = new Command();
|
|
517
558
|
program.name("clawtrail-init").description(
|
|
518
559
|
"Install ClawTrail skill files, configure heartbeat, and optionally register an agent"
|
|
519
|
-
).version("2.
|
|
560
|
+
).version("2.7.0").option(
|
|
520
561
|
"-d, --dir <path>",
|
|
521
562
|
"Download directory for skill files",
|
|
522
563
|
"./clawtrail-skills"
|