jules-orchestrator-kit 0.6.1 ā 0.6.3
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 +4 -0
- package/bin/init.js +37 -10
- package/package.json +1 -1
- package/scripts/jules-self-audit.mjs +1 -1
package/README.md
CHANGED
|
@@ -29,6 +29,10 @@ npm run jules:create "Refactor Auth"
|
|
|
29
29
|
npm run jules:queue
|
|
30
30
|
```
|
|
31
31
|
|
|
32
|
+
> š” **Vendored Scripts Architecture**:
|
|
33
|
+
> `npx jules-orchestrator-kit` (or `npx jules-init`) copies zero-dependency orchestration scripts directly into your project's `./scripts/` directory. This ensures full code transparency, auditability, and zero external dependency risk in CI.
|
|
34
|
+
> To update vendored scripts to the latest release, run `npx jules-orchestrator-kit --force`.
|
|
35
|
+
|
|
32
36
|
---
|
|
33
37
|
|
|
34
38
|
## How It Works
|
package/bin/init.js
CHANGED
|
@@ -237,6 +237,8 @@ if (fs.existsSync(targetPkgPath) && targetDir !== kitRoot) {
|
|
|
237
237
|
"jules:create": "node scripts/jules-create.mjs",
|
|
238
238
|
"jules:status": "node scripts/jules-status.mjs",
|
|
239
239
|
"jules:audit": "node scripts/jules-self-audit.mjs",
|
|
240
|
+
"jules:cleanup": "node scripts/jules-cleanup.mjs",
|
|
241
|
+
"jules:scan": "node scripts/jules-scan-todos.mjs",
|
|
240
242
|
"jules:swarm": "node scripts/jules-swarm.mjs",
|
|
241
243
|
"jules:nightly": "node scripts/jules-nightly.mjs"
|
|
242
244
|
};
|
|
@@ -257,9 +259,34 @@ if (fs.existsSync(targetPkgPath) && targetDir !== kitRoot) {
|
|
|
257
259
|
}
|
|
258
260
|
}
|
|
259
261
|
|
|
262
|
+
// 5b. Ensure target repository has .gitignore entries for sensitive and runtime state
|
|
263
|
+
const targetGitignorePath = path.join(targetDir, ".gitignore");
|
|
264
|
+
const requiredGitignoreEntries = [
|
|
265
|
+
".env",
|
|
266
|
+
".agent/history/",
|
|
267
|
+
".agent/state/",
|
|
268
|
+
".agent/jules-queue/*.md",
|
|
269
|
+
"!.agent/jules-queue/README.md"
|
|
270
|
+
];
|
|
271
|
+
|
|
272
|
+
let gitignoreContent = fs.existsSync(targetGitignorePath)
|
|
273
|
+
? fs.readFileSync(targetGitignorePath, "utf-8")
|
|
274
|
+
: "";
|
|
275
|
+
|
|
276
|
+
const missingEntries = requiredGitignoreEntries.filter(
|
|
277
|
+
(entry) => !gitignoreContent.includes(entry)
|
|
278
|
+
);
|
|
279
|
+
|
|
280
|
+
if (missingEntries.length > 0) {
|
|
281
|
+
const prefix = gitignoreContent && !gitignoreContent.endsWith("\n") ? "\n" : "";
|
|
282
|
+
const addedBlock = `${prefix}# Jules Orchestrator Runtime State & Credentials\n${missingEntries.join("\n")}\n`;
|
|
283
|
+
fs.appendFileSync(targetGitignorePath, addedBlock, "utf-8");
|
|
284
|
+
console.log("ā
Added required security entries to .gitignore");
|
|
285
|
+
}
|
|
286
|
+
|
|
260
287
|
console.log("\nš Google Jules Orchestration Kit successfully initialized!");
|
|
261
288
|
|
|
262
|
-
// 6. Generate
|
|
289
|
+
// 6. Generate Encoded Workspace Manifest (JULES_WEB_SETUP.md)
|
|
263
290
|
const agentState = {
|
|
264
291
|
v: 1,
|
|
265
292
|
schema: "jules.init/v1",
|
|
@@ -280,14 +307,14 @@ const hash = crypto.createHash("sha256").update(canonicalJson, "utf8").digest("h
|
|
|
280
307
|
const compressed = zlib.brotliCompressSync(Buffer.from(canonicalJson, "utf8"));
|
|
281
308
|
const payloadToken = `JULES1.${hash}.${compressed.toString("base64url")}`;
|
|
282
309
|
|
|
283
|
-
const setupMdContent = `#
|
|
310
|
+
const setupMdContent = `# Google Jules Encoded Workspace Manifest
|
|
284
311
|
|
|
285
312
|
> **Generated**: ${agentState.generatedAt}
|
|
286
|
-
> **
|
|
313
|
+
> **Workspace Manifest Code**: \`${payloadToken}\`
|
|
287
314
|
|
|
288
|
-
## š
|
|
289
|
-
1.
|
|
290
|
-
2.
|
|
315
|
+
## š Official Setup & Documentation
|
|
316
|
+
1. Documentation & Guide: https://jules.google
|
|
317
|
+
2. Workspace Manifest Code:
|
|
291
318
|
\`\`\`
|
|
292
319
|
${payloadToken}
|
|
293
320
|
\`\`\`
|
|
@@ -300,12 +327,12 @@ ${payloadToken}
|
|
|
300
327
|
|
|
301
328
|
fs.writeFileSync(path.join(targetDir, ".agent", "JULES_WEB_SETUP.md"), setupMdContent, "utf-8");
|
|
302
329
|
|
|
303
|
-
console.log("\nš
|
|
330
|
+
console.log("\nš Google Jules Setup Complete");
|
|
304
331
|
console.log(" Your local agent configurations are ready.");
|
|
305
|
-
console.log(` š
|
|
306
|
-
console.log("\n (A backup
|
|
332
|
+
console.log(` š Encoded Workspace Manifest: \x1b[36m${payloadToken}\x1b[0m`);
|
|
333
|
+
console.log("\n (A backup was written to .agent/JULES_WEB_SETUP.md)");
|
|
307
334
|
console.log("\nNext Steps:");
|
|
308
|
-
console.log(" 1.
|
|
335
|
+
console.log(" 1. See official documentation at https://jules.google");
|
|
309
336
|
console.log(" 2. Set environment variables: JULES_REPO=\"owner/repo\"");
|
|
310
337
|
console.log(" 3. Scaffold a new task: npm run jules:create \"My Feature\"");
|
|
311
338
|
console.log(" 4. Dispatch the queue: npm run jules:queue");
|
package/package.json
CHANGED
|
@@ -264,7 +264,7 @@ export function runSelfAudit() {
|
|
|
264
264
|
log.info("Analyzing Code Diff Payload Size & Content...");
|
|
265
265
|
const codeDiffPayload = changedCodeFiles.length > 0
|
|
266
266
|
? runGitCommand(["diff", `${mergeBase}...HEAD`, "--", ...changedCodeFiles], true)
|
|
267
|
-
:
|
|
267
|
+
: "";
|
|
268
268
|
|
|
269
269
|
const diffBytes = Buffer.byteLength(codeDiffPayload, "utf8");
|
|
270
270
|
const maxDiffBytes = 75 * 1024; // 75 KB
|