@karmaniverous/jeeves 0.4.4 → 0.4.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/dist/cli/jeeves/index.js +2 -2
- package/dist/cli/plugin/index.js +2 -2
- package/dist/cli/service/index.js +9 -10
- package/dist/index.d.ts +1 -0
- package/dist/index.js +11 -12
- package/package.json +2 -2
package/dist/cli/jeeves/index.js
CHANGED
|
@@ -261,14 +261,14 @@ const PLATFORM_COMPONENTS = [
|
|
|
261
261
|
* Core library version, inlined at build time.
|
|
262
262
|
*
|
|
263
263
|
* @remarks
|
|
264
|
-
* The `0.4.
|
|
264
|
+
* The `0.4.4` placeholder is replaced by
|
|
265
265
|
* `@rollup/plugin-replace` during the build with the actual version
|
|
266
266
|
* from `package.json`. This ensures the correct version survives
|
|
267
267
|
* when consumers bundle core into their own dist (where runtime
|
|
268
268
|
* `import.meta.url`-based resolution would find the wrong package.json).
|
|
269
269
|
*/
|
|
270
270
|
/** The core library version from package.json (inlined at build time). */
|
|
271
|
-
const CORE_VERSION = '0.4.
|
|
271
|
+
const CORE_VERSION = '0.4.4';
|
|
272
272
|
|
|
273
273
|
/**
|
|
274
274
|
* Dynamic discovery of installed Jeeves component CLIs.
|
package/dist/cli/plugin/index.js
CHANGED
|
@@ -119,14 +119,14 @@ const COMPONENT_VERSIONS_FILE = 'component-versions.json';
|
|
|
119
119
|
* Core library version, inlined at build time.
|
|
120
120
|
*
|
|
121
121
|
* @remarks
|
|
122
|
-
* The `0.4.
|
|
122
|
+
* The `0.4.4` placeholder is replaced by
|
|
123
123
|
* `@rollup/plugin-replace` during the build with the actual version
|
|
124
124
|
* from `package.json`. This ensures the correct version survives
|
|
125
125
|
* when consumers bundle core into their own dist (where runtime
|
|
126
126
|
* `import.meta.url`-based resolution would find the wrong package.json).
|
|
127
127
|
*/
|
|
128
128
|
/** The core library version from package.json (inlined at build time). */
|
|
129
|
-
const CORE_VERSION = '0.4.
|
|
129
|
+
const CORE_VERSION = '0.4.4';
|
|
130
130
|
|
|
131
131
|
/**
|
|
132
132
|
* Shared file I/O helpers for managed section operations.
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import { execSync, spawn } from 'node:child_process';
|
|
3
2
|
import { existsSync, unlinkSync, mkdirSync, writeFileSync, readFileSync } from 'node:fs';
|
|
4
3
|
import { join } from 'node:path';
|
|
5
4
|
import * as commander from 'commander';
|
|
6
5
|
import { z } from 'zod';
|
|
6
|
+
import { execSync } from 'node:child_process';
|
|
7
7
|
import { homedir } from 'node:os';
|
|
8
8
|
|
|
9
9
|
function getDefaultExportFromCjs (x) {
|
|
@@ -185,12 +185,17 @@ z.object({
|
|
|
185
185
|
.optional(),
|
|
186
186
|
/**
|
|
187
187
|
* Returns command + args for launching the service process.
|
|
188
|
-
* Consumed by `
|
|
188
|
+
* Consumed by `service install`.
|
|
189
189
|
*/
|
|
190
190
|
startCommand: z.function({
|
|
191
191
|
input: [z.string()],
|
|
192
192
|
output: z.array(z.string()),
|
|
193
193
|
}),
|
|
194
|
+
/** In-process service entry point for the CLI `start` command. */
|
|
195
|
+
run: z.function({
|
|
196
|
+
input: [z.string()],
|
|
197
|
+
output: z.promise(z.void()),
|
|
198
|
+
}),
|
|
194
199
|
/** TOOLS.md section name (e.g., 'Watcher'). */
|
|
195
200
|
sectionId: z.string().min(1, 'sectionId must be a non-empty string'),
|
|
196
201
|
/** Refresh interval in seconds (must be a prime number). */
|
|
@@ -710,14 +715,8 @@ function createServiceCli(descriptor) {
|
|
|
710
715
|
.command('start')
|
|
711
716
|
.description('Launch the service process (foreground)')
|
|
712
717
|
.requiredOption('-c, --config <path>', 'Config file path')
|
|
713
|
-
.action((opts) => {
|
|
714
|
-
|
|
715
|
-
const proc = spawn(cmdArgs[0], cmdArgs.slice(1), {
|
|
716
|
-
stdio: 'inherit',
|
|
717
|
-
});
|
|
718
|
-
proc.on('exit', (code) => {
|
|
719
|
-
process.exit(code ?? 1);
|
|
720
|
-
});
|
|
718
|
+
.action(async (opts) => {
|
|
719
|
+
await descriptor.run(opts.config);
|
|
721
720
|
});
|
|
722
721
|
// --- status ---
|
|
723
722
|
program
|
package/dist/index.d.ts
CHANGED
|
@@ -118,6 +118,7 @@ declare const jeevesComponentDescriptorSchema: z.ZodObject<{
|
|
|
118
118
|
onConfigApply: z.ZodOptional<z.ZodFunction<z.ZodTuple<readonly [z.ZodRecord<z.ZodString, z.ZodUnknown>], null>, z.ZodPromise<z.ZodVoid>>>;
|
|
119
119
|
customMerge: z.ZodOptional<z.ZodFunction<z.ZodTuple<readonly [z.ZodRecord<z.ZodString, z.ZodUnknown>, z.ZodRecord<z.ZodString, z.ZodUnknown>], null>, z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
120
120
|
startCommand: z.ZodFunction<z.ZodTuple<readonly [z.ZodString], null>, z.ZodArray<z.ZodString>>;
|
|
121
|
+
run: z.ZodFunction<z.ZodTuple<readonly [z.ZodString], null>, z.ZodPromise<z.ZodVoid>>;
|
|
121
122
|
sectionId: z.ZodString;
|
|
122
123
|
refreshIntervalSeconds: z.ZodNumber;
|
|
123
124
|
generateToolsContent: z.ZodFunction<z.ZodTuple<readonly [], null>, z.ZodString>;
|
package/dist/index.js
CHANGED
|
@@ -5,8 +5,8 @@ import { JSONPath } from 'jsonpath-plus';
|
|
|
5
5
|
import * as commander from 'commander';
|
|
6
6
|
import { valid, gte, gt } from 'semver';
|
|
7
7
|
import { homedir } from 'node:os';
|
|
8
|
-
import { execSync, spawn } from 'node:child_process';
|
|
9
8
|
import { z } from 'zod';
|
|
9
|
+
import { execSync } from 'node:child_process';
|
|
10
10
|
import { fileURLToPath } from 'node:url';
|
|
11
11
|
import { packageDirectorySync } from 'package-directory';
|
|
12
12
|
|
|
@@ -176,14 +176,14 @@ const PLATFORM_COMPONENTS = [
|
|
|
176
176
|
* Core library version, inlined at build time.
|
|
177
177
|
*
|
|
178
178
|
* @remarks
|
|
179
|
-
* The `0.4.
|
|
179
|
+
* The `0.4.4` placeholder is replaced by
|
|
180
180
|
* `@rollup/plugin-replace` during the build with the actual version
|
|
181
181
|
* from `package.json`. This ensures the correct version survives
|
|
182
182
|
* when consumers bundle core into their own dist (where runtime
|
|
183
183
|
* `import.meta.url`-based resolution would find the wrong package.json).
|
|
184
184
|
*/
|
|
185
185
|
/** The core library version from package.json (inlined at build time). */
|
|
186
|
-
const CORE_VERSION = '0.4.
|
|
186
|
+
const CORE_VERSION = '0.4.4';
|
|
187
187
|
|
|
188
188
|
/**
|
|
189
189
|
* Workspace and config root initialization.
|
|
@@ -1537,12 +1537,17 @@ const jeevesComponentDescriptorSchema = z.object({
|
|
|
1537
1537
|
.optional(),
|
|
1538
1538
|
/**
|
|
1539
1539
|
* Returns command + args for launching the service process.
|
|
1540
|
-
* Consumed by `
|
|
1540
|
+
* Consumed by `service install`.
|
|
1541
1541
|
*/
|
|
1542
1542
|
startCommand: z.function({
|
|
1543
1543
|
input: [z.string()],
|
|
1544
1544
|
output: z.array(z.string()),
|
|
1545
1545
|
}),
|
|
1546
|
+
/** In-process service entry point for the CLI `start` command. */
|
|
1547
|
+
run: z.function({
|
|
1548
|
+
input: [z.string()],
|
|
1549
|
+
output: z.promise(z.void()),
|
|
1550
|
+
}),
|
|
1546
1551
|
/** TOOLS.md section name (e.g., 'Watcher'). */
|
|
1547
1552
|
sectionId: z.string().min(1, 'sectionId must be a non-empty string'),
|
|
1548
1553
|
/** Refresh interval in seconds (must be a prime number). */
|
|
@@ -2053,14 +2058,8 @@ function createServiceCli(descriptor) {
|
|
|
2053
2058
|
.command('start')
|
|
2054
2059
|
.description('Launch the service process (foreground)')
|
|
2055
2060
|
.requiredOption('-c, --config <path>', 'Config file path')
|
|
2056
|
-
.action((opts) => {
|
|
2057
|
-
|
|
2058
|
-
const proc = spawn(cmdArgs[0], cmdArgs.slice(1), {
|
|
2059
|
-
stdio: 'inherit',
|
|
2060
|
-
});
|
|
2061
|
-
proc.on('exit', (code) => {
|
|
2062
|
-
process.exit(code ?? 1);
|
|
2063
|
-
});
|
|
2061
|
+
.action(async (opts) => {
|
|
2062
|
+
await descriptor.run(opts.config);
|
|
2064
2063
|
});
|
|
2065
2064
|
// --- status ---
|
|
2066
2065
|
program
|
package/package.json
CHANGED
|
@@ -50,7 +50,7 @@
|
|
|
50
50
|
"prettier": "^3.8.1",
|
|
51
51
|
"release-it": "^19.2.4",
|
|
52
52
|
"rimraf": "^6.1.3",
|
|
53
|
-
"rollup": "^4.60.
|
|
53
|
+
"rollup": "^4.60.1",
|
|
54
54
|
"rollup-plugin-dts": "^6.4.1",
|
|
55
55
|
"tslib": "^2.8.1",
|
|
56
56
|
"typedoc": "^0.28.18",
|
|
@@ -139,5 +139,5 @@
|
|
|
139
139
|
},
|
|
140
140
|
"type": "module",
|
|
141
141
|
"types": "dist/index.d.ts",
|
|
142
|
-
"version": "0.4.
|
|
142
|
+
"version": "0.4.5"
|
|
143
143
|
}
|