@karmaniverous/jeeves 0.4.2 → 0.4.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/dist/cli/jeeves/index.js +2 -2
- package/dist/cli/plugin/index.js +2 -2
- package/dist/cli/service/index.js +7 -7
- package/dist/index.d.ts +1 -1
- package/dist/index.js +12 -10
- package/package.json +1 -1
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.2` 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.2';
|
|
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.2` 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.2';
|
|
130
130
|
|
|
131
131
|
/**
|
|
132
132
|
* Shared file I/O helpers for managed section operations.
|
|
@@ -674,7 +674,7 @@ function createServiceManager(descriptor) {
|
|
|
674
674
|
* Standard commands:
|
|
675
675
|
* - `start -c <path>` - Launch the service process (foreground)
|
|
676
676
|
* - `status [-p port]` - Probe service health
|
|
677
|
-
* - `config [jsonpath] [-p port]` - Query running config
|
|
677
|
+
* - `config [jsonpath] [-p port]` - Query running config (jsonpath optional)
|
|
678
678
|
* - `config validate -c <path>` - Validate a config file
|
|
679
679
|
* - `config apply [-p port] [--file path] [--replace]` - Apply config patch
|
|
680
680
|
* - `init [-o path]` - Generate default config
|
|
@@ -730,10 +730,7 @@ function createServiceCli(descriptor) {
|
|
|
730
730
|
// --- config ---
|
|
731
731
|
const configCmd = program
|
|
732
732
|
.command('config')
|
|
733
|
-
.description('Query or manage service configuration')
|
|
734
|
-
configCmd
|
|
735
|
-
.command('query')
|
|
736
|
-
.description('Query running service config via JSONPath')
|
|
733
|
+
.description('Query or manage service configuration')
|
|
737
734
|
.argument('[jsonpath]', 'JSONPath expression')
|
|
738
735
|
.option('-p, --port <port>', 'Service port', String(descriptor.defaultPort))
|
|
739
736
|
.action(async (jsonpath, opts) => {
|
|
@@ -790,9 +787,12 @@ function createServiceCli(descriptor) {
|
|
|
790
787
|
patch = JSON.parse(input);
|
|
791
788
|
}
|
|
792
789
|
}
|
|
793
|
-
const
|
|
790
|
+
const body = { patch };
|
|
791
|
+
if (opts.replace) {
|
|
792
|
+
body.replace = true;
|
|
793
|
+
}
|
|
794
794
|
try {
|
|
795
|
-
const result = await postJson(`${url}/config/apply
|
|
795
|
+
const result = await postJson(`${url}/config/apply`, body);
|
|
796
796
|
console.log(JSON.stringify(result, null, 2));
|
|
797
797
|
}
|
|
798
798
|
catch (err) {
|
package/dist/index.d.ts
CHANGED
|
@@ -394,7 +394,7 @@ declare function createPluginCli(options: CreatePluginCliOptions): Command;
|
|
|
394
394
|
* Standard commands:
|
|
395
395
|
* - `start -c <path>` - Launch the service process (foreground)
|
|
396
396
|
* - `status [-p port]` - Probe service health
|
|
397
|
-
* - `config [jsonpath] [-p port]` - Query running config
|
|
397
|
+
* - `config [jsonpath] [-p port]` - Query running config (jsonpath optional)
|
|
398
398
|
* - `config validate -c <path>` - Validate a config file
|
|
399
399
|
* - `config apply [-p port] [--file path] [--replace]` - Apply config patch
|
|
400
400
|
* - `init [-o path]` - Generate default config
|
package/dist/index.js
CHANGED
|
@@ -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.2` 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.2';
|
|
187
187
|
|
|
188
188
|
/**
|
|
189
189
|
* Workspace and config root initialization.
|
|
@@ -2005,7 +2005,7 @@ function createServiceManager(descriptor) {
|
|
|
2005
2005
|
* Standard commands:
|
|
2006
2006
|
* - `start -c <path>` - Launch the service process (foreground)
|
|
2007
2007
|
* - `status [-p port]` - Probe service health
|
|
2008
|
-
* - `config [jsonpath] [-p port]` - Query running config
|
|
2008
|
+
* - `config [jsonpath] [-p port]` - Query running config (jsonpath optional)
|
|
2009
2009
|
* - `config validate -c <path>` - Validate a config file
|
|
2010
2010
|
* - `config apply [-p port] [--file path] [--replace]` - Apply config patch
|
|
2011
2011
|
* - `init [-o path]` - Generate default config
|
|
@@ -2061,10 +2061,7 @@ function createServiceCli(descriptor) {
|
|
|
2061
2061
|
// --- config ---
|
|
2062
2062
|
const configCmd = program
|
|
2063
2063
|
.command('config')
|
|
2064
|
-
.description('Query or manage service configuration')
|
|
2065
|
-
configCmd
|
|
2066
|
-
.command('query')
|
|
2067
|
-
.description('Query running service config via JSONPath')
|
|
2064
|
+
.description('Query or manage service configuration')
|
|
2068
2065
|
.argument('[jsonpath]', 'JSONPath expression')
|
|
2069
2066
|
.option('-p, --port <port>', 'Service port', String(descriptor.defaultPort))
|
|
2070
2067
|
.action(async (jsonpath, opts) => {
|
|
@@ -2121,9 +2118,12 @@ function createServiceCli(descriptor) {
|
|
|
2121
2118
|
patch = JSON.parse(input);
|
|
2122
2119
|
}
|
|
2123
2120
|
}
|
|
2124
|
-
const
|
|
2121
|
+
const body = { patch };
|
|
2122
|
+
if (opts.replace) {
|
|
2123
|
+
body.replace = true;
|
|
2124
|
+
}
|
|
2125
2125
|
try {
|
|
2126
|
-
const result = await postJson(`${url}/config/apply
|
|
2126
|
+
const result = await postJson(`${url}/config/apply`, body);
|
|
2127
2127
|
console.log(JSON.stringify(result, null, 2));
|
|
2128
2128
|
}
|
|
2129
2129
|
catch (err) {
|
|
@@ -3859,7 +3859,9 @@ function createPluginToolset(descriptor) {
|
|
|
3859
3859
|
return fail('Missing required parameter: config');
|
|
3860
3860
|
}
|
|
3861
3861
|
try {
|
|
3862
|
-
const result = await postJson(`${baseUrl}/config/apply`,
|
|
3862
|
+
const result = await postJson(`${baseUrl}/config/apply`, {
|
|
3863
|
+
patch: config,
|
|
3864
|
+
});
|
|
3863
3865
|
return ok(result);
|
|
3864
3866
|
}
|
|
3865
3867
|
catch (err) {
|
package/package.json
CHANGED