@serviceme/devtools-cli 2.0.3 → 2.0.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/bridgeServer.js +4 -3
- package/dist/cli.js +22 -9
- package/package.json +4 -4
package/dist/bridgeServer.js
CHANGED
|
@@ -1363,7 +1363,7 @@ var import_dist = (/* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
1363
1363
|
return isRecord$3(value) && typeof value.valid === "boolean";
|
|
1364
1364
|
}
|
|
1365
1365
|
const SERVICEME_CLI_NAME = "serviceme";
|
|
1366
|
-
const SERVICEME_CLI_VERSION = "2.0.
|
|
1366
|
+
const SERVICEME_CLI_VERSION = "2.0.5";
|
|
1367
1367
|
const SERVICEME_CLI_CAPABILITIES = {
|
|
1368
1368
|
bridge: true,
|
|
1369
1369
|
tasks: 1,
|
|
@@ -1377,7 +1377,8 @@ var import_dist = (/* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
1377
1377
|
}
|
|
1378
1378
|
function isServiceMeProjectScaffoldPruneResult(value) {
|
|
1379
1379
|
if (!isRecord$2(value)) return false;
|
|
1380
|
-
|
|
1380
|
+
const isOptionalStringArray = (entry) => entry === void 0 || Array.isArray(entry) && entry.every((item) => typeof item === "string");
|
|
1381
|
+
return typeof value.applied === "boolean" && typeof value.preset === "string" && typeof value.projectRoot === "string" && isOptionalStringArray(value.disabledModules) && isOptionalStringArray(value.recommendedNextSteps) && Array.isArray(value.commands) && value.commands.every((command) => typeof command === "string");
|
|
1381
1382
|
}
|
|
1382
1383
|
function isServiceMeProjectGitInitResult(value) {
|
|
1383
1384
|
return isRecord$2(value) && typeof value.initialized === "boolean" && typeof value.command === "string";
|
|
@@ -1648,7 +1649,7 @@ var import_dist = (/* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
1648
1649
|
exports.normalizeBridgeMethod = normalizeBridgeMethod;
|
|
1649
1650
|
exports.normalizeServicemeError = normalizeServicemeError;
|
|
1650
1651
|
})))();
|
|
1651
|
-
const SERVICEME_CLI_VERSION = "2.0.
|
|
1652
|
+
const SERVICEME_CLI_VERSION = "2.0.5";
|
|
1652
1653
|
//#endregion
|
|
1653
1654
|
//#region src/bridge/CopilotContentBridgeHandler.ts
|
|
1654
1655
|
/**
|
package/dist/cli.js
CHANGED
|
@@ -1378,7 +1378,7 @@ var import_dist = (/* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
1378
1378
|
return isRecord$3(value) && typeof value.valid === "boolean";
|
|
1379
1379
|
}
|
|
1380
1380
|
const SERVICEME_CLI_NAME = "serviceme";
|
|
1381
|
-
const SERVICEME_CLI_VERSION = "2.0.
|
|
1381
|
+
const SERVICEME_CLI_VERSION = "2.0.5";
|
|
1382
1382
|
const SERVICEME_CLI_CAPABILITIES = {
|
|
1383
1383
|
bridge: true,
|
|
1384
1384
|
tasks: 1,
|
|
@@ -1392,7 +1392,8 @@ var import_dist = (/* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
1392
1392
|
}
|
|
1393
1393
|
function isServiceMeProjectScaffoldPruneResult(value) {
|
|
1394
1394
|
if (!isRecord$2(value)) return false;
|
|
1395
|
-
|
|
1395
|
+
const isOptionalStringArray = (entry) => entry === void 0 || Array.isArray(entry) && entry.every((item) => typeof item === "string");
|
|
1396
|
+
return typeof value.applied === "boolean" && typeof value.preset === "string" && typeof value.projectRoot === "string" && isOptionalStringArray(value.disabledModules) && isOptionalStringArray(value.recommendedNextSteps) && Array.isArray(value.commands) && value.commands.every((command) => typeof command === "string");
|
|
1396
1397
|
}
|
|
1397
1398
|
function isServiceMeProjectGitInitResult(value) {
|
|
1398
1399
|
return isRecord$2(value) && typeof value.initialized === "boolean" && typeof value.command === "string";
|
|
@@ -1666,6 +1667,13 @@ var import_dist = (/* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
1666
1667
|
function parseArgs(argv) {
|
|
1667
1668
|
const positionals = [];
|
|
1668
1669
|
const flags = /* @__PURE__ */ new Map();
|
|
1670
|
+
const occurrences = /* @__PURE__ */ new Map();
|
|
1671
|
+
const record = (name, value) => {
|
|
1672
|
+
flags.set(name, value);
|
|
1673
|
+
const seen = occurrences.get(name);
|
|
1674
|
+
if (seen) seen.push(value);
|
|
1675
|
+
else occurrences.set(name, [value]);
|
|
1676
|
+
};
|
|
1669
1677
|
for (let index = 0; index < argv.length; index += 1) {
|
|
1670
1678
|
const token = argv[index];
|
|
1671
1679
|
if (!token) continue;
|
|
@@ -1676,20 +1684,21 @@ function parseArgs(argv) {
|
|
|
1676
1684
|
const withoutPrefix = token.slice(2);
|
|
1677
1685
|
const eqIndex = withoutPrefix.indexOf("=");
|
|
1678
1686
|
if (eqIndex >= 0) {
|
|
1679
|
-
|
|
1687
|
+
record(withoutPrefix.slice(0, eqIndex), withoutPrefix.slice(eqIndex + 1));
|
|
1680
1688
|
continue;
|
|
1681
1689
|
}
|
|
1682
1690
|
const next = argv[index + 1];
|
|
1683
1691
|
if (next && !next.startsWith("--")) {
|
|
1684
|
-
|
|
1692
|
+
record(withoutPrefix, next);
|
|
1685
1693
|
index += 1;
|
|
1686
1694
|
continue;
|
|
1687
1695
|
}
|
|
1688
|
-
|
|
1696
|
+
record(withoutPrefix, true);
|
|
1689
1697
|
}
|
|
1690
1698
|
return {
|
|
1691
1699
|
positionals,
|
|
1692
|
-
flags
|
|
1700
|
+
flags,
|
|
1701
|
+
occurrences
|
|
1693
1702
|
};
|
|
1694
1703
|
}
|
|
1695
1704
|
function getBooleanFlag(parsed, name) {
|
|
@@ -1699,6 +1708,10 @@ function getStringFlag(parsed, name) {
|
|
|
1699
1708
|
const value = parsed.flags.get(name);
|
|
1700
1709
|
return typeof value === "string" ? value : void 0;
|
|
1701
1710
|
}
|
|
1711
|
+
/** All string values of a repeatable flag, in order of appearance. */
|
|
1712
|
+
function getStringFlags(parsed, name) {
|
|
1713
|
+
return (parsed.occurrences.get(name) ?? []).filter((value) => typeof value === "string");
|
|
1714
|
+
}
|
|
1702
1715
|
//#endregion
|
|
1703
1716
|
//#region src/output.ts
|
|
1704
1717
|
function writeJson(value) {
|
|
@@ -2056,7 +2069,7 @@ async function handleSwitch(parsed) {
|
|
|
2056
2069
|
//#endregion
|
|
2057
2070
|
//#region src/version.ts
|
|
2058
2071
|
const SERVICEME_CLI_NAME = "serviceme";
|
|
2059
|
-
const SERVICEME_CLI_VERSION = "2.0.
|
|
2072
|
+
const SERVICEME_CLI_VERSION = "2.0.5";
|
|
2060
2073
|
//#endregion
|
|
2061
2074
|
//#region src/bridge/CopilotContentBridgeHandler.ts
|
|
2062
2075
|
var CopilotContentBridgeHandler_exports = /* @__PURE__ */ __exportAll({ CopilotContentBridgeHandler: () => CopilotContentBridgeHandler });
|
|
@@ -4824,7 +4837,7 @@ async function runProjectCommand(parsed) {
|
|
|
4824
4837
|
writeSuccess(await projectTools.initializeGit(workspacePath));
|
|
4825
4838
|
return;
|
|
4826
4839
|
case "scaffold-prune":
|
|
4827
|
-
writeSuccess(await projectTools.runScaffoldPrune(workspacePath, getStringFlag(parsed, "preset")));
|
|
4840
|
+
writeSuccess(await projectTools.runScaffoldPrune(workspacePath, getStringFlag(parsed, "preset"), { disabledModules: getStringFlags(parsed, "no-module") }));
|
|
4828
4841
|
return;
|
|
4829
4842
|
default: throw new Error("Unsupported project command. Use extract-template, scaffold-prune, git-init, make-scripts-executable, or install-deps.");
|
|
4830
4843
|
}
|
|
@@ -6533,7 +6546,7 @@ function printUsage() {
|
|
|
6533
6546
|
" serviceme project git-init --workspacePath <path> --json",
|
|
6534
6547
|
" serviceme project install-deps --workspacePath <path> --command <cmd> --json",
|
|
6535
6548
|
" serviceme project make-scripts-executable --workspacePath <path> --json",
|
|
6536
|
-
" serviceme project scaffold-prune --workspacePath <path> --preset <id> --json",
|
|
6549
|
+
" serviceme project scaffold-prune --workspacePath <path> --preset <id> [--no-module <id>]... --json",
|
|
6537
6550
|
" serviceme env check --json",
|
|
6538
6551
|
" serviceme copilot doctor --json",
|
|
6539
6552
|
" serviceme copilot prompt --prompt <text> [--workspace <path>] [--autopilot] [--allow-tool <tools>] [--timeout <ms>] --json",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@serviceme/devtools-cli",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.5",
|
|
4
4
|
"description": "Unified SERVICEME CLI for automation, project scaffolding, and bridge-based tooling.",
|
|
5
5
|
"license": "SEE LICENSE IN LICENSE.md",
|
|
6
6
|
"repository": {
|
|
@@ -39,9 +39,9 @@
|
|
|
39
39
|
"registry": "https://registry.npmjs.org/"
|
|
40
40
|
},
|
|
41
41
|
"dependencies": {
|
|
42
|
-
"@serviceme/devtools-core": "2.0.
|
|
43
|
-
"@serviceme/devtools-protocol": "2.0.
|
|
44
|
-
"@serviceme/devtools-shared": "2.0.
|
|
42
|
+
"@serviceme/devtools-core": "2.0.5",
|
|
43
|
+
"@serviceme/devtools-protocol": "2.0.5",
|
|
44
|
+
"@serviceme/devtools-shared": "2.0.5"
|
|
45
45
|
},
|
|
46
46
|
"devDependencies": {
|
|
47
47
|
"@types/node": "^24",
|