@kybernesis/create 0.14.0 → 0.14.2
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/systemd.js +14 -1
- package/dist/upgrade.js +11 -1
- package/package.json +2 -2
package/dist/systemd.js
CHANGED
|
@@ -72,11 +72,24 @@ export function reconcileManageRestart(cwd, name) {
|
|
|
72
72
|
return "blocked";
|
|
73
73
|
}
|
|
74
74
|
}
|
|
75
|
+
function dropIns(dir) {
|
|
76
|
+
try {
|
|
77
|
+
return readdirSync(dir)
|
|
78
|
+
.filter((name) => name.endsWith(".conf"))
|
|
79
|
+
.sort()
|
|
80
|
+
.map((name) => readFileSync(join(dir, name), "utf8"));
|
|
81
|
+
}
|
|
82
|
+
catch {
|
|
83
|
+
return [];
|
|
84
|
+
}
|
|
85
|
+
}
|
|
75
86
|
export function findMatchingAgentServiceUnit(cwd, systemdDir = "/etc/systemd/system") {
|
|
76
87
|
try {
|
|
77
88
|
for (const file of readdirSync(systemdDir).filter((entry) => entry.endsWith("-agent.service"))) {
|
|
78
89
|
const path = join(systemdDir, file);
|
|
79
|
-
|
|
90
|
+
// The effective unit is the file plus its drop-ins (<unit>.d/*.conf, in
|
|
91
|
+
// name order) — a build gate added through `systemctl edit` counts.
|
|
92
|
+
const contents = [readFileSync(path, "utf8"), ...dropIns(`${path}.d`)].join("\n");
|
|
80
93
|
const values = parseAgentServiceUnit(path, contents);
|
|
81
94
|
if (values && resolve(values.app) === resolve(cwd)) {
|
|
82
95
|
return { path, contents, values, mode: statSync(path).mode & 0o777 };
|
package/dist/upgrade.js
CHANGED
|
@@ -376,7 +376,17 @@ export async function upgrade(skipEval) {
|
|
|
376
376
|
return;
|
|
377
377
|
}
|
|
378
378
|
console.log(bold(`\nInstalling: ${toUpgrade.join(", ")}\n`));
|
|
379
|
-
|
|
379
|
+
/**
|
|
380
|
+
* One install, with peers relaxed. Every @kybernesis package peers on a
|
|
381
|
+
* narrow eve range, and eve moves with them: the installed set demands the
|
|
382
|
+
* old eve, the new set demands the new one, and npm's resolver refuses
|
|
383
|
+
* either order — eve first, packages first, or all at once — under strict
|
|
384
|
+
* peers (seen on Kyber moving 0.38 → 0.49: ERESOLVE all three ways). The
|
|
385
|
+
* set being installed is exactly the certified combination, so relaxing
|
|
386
|
+
* peer resolution for this one command changes nothing about what ends up
|
|
387
|
+
* on disk; the version check above is what guards correctness.
|
|
388
|
+
*/
|
|
389
|
+
run("npm", ["install", ...toUpgrade, "--legacy-peer-deps"], { cwd });
|
|
380
390
|
/**
|
|
381
391
|
* Repairs run AFTER the install, not before.
|
|
382
392
|
*
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@kybernesis/create",
|
|
3
|
-
"version": "0.14.
|
|
4
|
-
"description": "The Kybernesis agent scaffolder and FDE toolkit: one command to a governed, remembering, multiplayer, self-testing eve agent
|
|
3
|
+
"version": "0.14.2",
|
|
4
|
+
"description": "The Kybernesis agent scaffolder and FDE toolkit: one command to a governed, remembering, multiplayer, self-testing eve agent — plus doctor and upgrade.",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"homepage": "https://kybernesis.ai",
|