@getmikie/cli 1.1.108 → 1.1.113
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 +14 -11
- package/bin/mikie.mjs +13 -2
- package/lib/launcher.mjs +7 -0
- package/lib/update.mjs +27 -9
- package/package.json +5 -5
package/README.md
CHANGED
|
@@ -3,28 +3,29 @@
|
|
|
3
3
|
This package is a thin launcher for Mikie's compiled native relay.
|
|
4
4
|
|
|
5
5
|
```sh
|
|
6
|
-
npx -
|
|
6
|
+
npx --yes --ignore-scripts --registry=https://registry.npmjs.org @getmikie/cli@1.1.108 mcp
|
|
7
7
|
```
|
|
8
8
|
|
|
9
9
|
For a persistent command path on Windows PowerShell:
|
|
10
10
|
|
|
11
11
|
```powershell
|
|
12
|
-
npm.cmd install --global @getmikie/cli@
|
|
12
|
+
npm.cmd install --global @getmikie/cli@1.1.108 --ignore-scripts --registry=https://registry.npmjs.org
|
|
13
13
|
```
|
|
14
14
|
|
|
15
|
-
Mikie does not change your PowerShell execution policy.
|
|
16
|
-
command
|
|
17
|
-
|
|
18
|
-
directory.
|
|
15
|
+
Mikie does not change your PowerShell execution policy. Keep the exact package
|
|
16
|
+
name in the command: without naming the package as the install target, npm
|
|
17
|
+
incorrectly targets the current directory.
|
|
19
18
|
|
|
20
19
|
For a persistent command path on macOS or Linux:
|
|
21
20
|
|
|
22
21
|
```sh
|
|
23
|
-
npm install --global @getmikie/cli@
|
|
22
|
+
npm install --global @getmikie/cli@1.1.108 --ignore-scripts --registry=https://registry.npmjs.org
|
|
24
23
|
```
|
|
25
24
|
|
|
26
|
-
|
|
27
|
-
|
|
25
|
+
These portable npm commands disable every lifecycle script and pin the public
|
|
26
|
+
npm registry. The public OS installers additionally authenticate exact wrapper
|
|
27
|
+
and native tarball bytes, install them offline, and explicitly run only Mikie's
|
|
28
|
+
authenticated reconciliation script.
|
|
28
29
|
|
|
29
30
|
Then run:
|
|
30
31
|
|
|
@@ -46,7 +47,9 @@ mikie control run --request C:\absolute\path\control-request.json --json
|
|
|
46
47
|
```
|
|
47
48
|
|
|
48
49
|
The request must be an existing absolute JSON file. Mikie validates the frozen
|
|
49
|
-
repository, allowed paths,
|
|
50
|
-
|
|
50
|
+
repository, allowed paths, exact model and reasoning effort, bounded model-turn
|
|
51
|
+
timeout, and private temporary root before execution. The verifier argv is
|
|
52
|
+
restricted to `git diff --check`; interpreters, build tools, and test runners
|
|
53
|
+
that could execute repository-controlled code are rejected. The JSON result is
|
|
51
54
|
content-free: it reports terminal status and hashes, never prompts, context,
|
|
52
55
|
patch bodies, verifier output, or credentials.
|
package/bin/mikie.mjs
CHANGED
|
@@ -47,12 +47,23 @@ if (["--version", "-v"].includes(singleFlag)) {
|
|
|
47
47
|
console.log(`Mikie ${packageMetadata.version}
|
|
48
48
|
|
|
49
49
|
Usage:
|
|
50
|
+
mikie savings history [options]
|
|
51
|
+
mikie savings export-meter-history
|
|
50
52
|
mikie mcp [--adapter codex|claude_code]
|
|
51
53
|
mikie login
|
|
52
|
-
mikie
|
|
54
|
+
mikie logout
|
|
55
|
+
mikie connect .|<absolute-directory>
|
|
56
|
+
mikie privacy review
|
|
57
|
+
mikie setup codex
|
|
58
|
+
mikie setup claude
|
|
59
|
+
mikie mode codex [active|shadow] [--json]
|
|
53
60
|
mikie control run --request <absolute-json> --json
|
|
54
|
-
mikie doctor
|
|
61
|
+
mikie doctor [--client codex]
|
|
55
62
|
mikie update
|
|
63
|
+
mikie device revoke
|
|
64
|
+
mikie uninstall
|
|
65
|
+
mikie --help
|
|
66
|
+
mikie --version
|
|
56
67
|
|
|
57
68
|
All commands execute the compiled Mikie native engine.`);
|
|
58
69
|
} else if (arguments_.length === 1 && arguments_[0].toLowerCase() === "update") {
|
package/lib/launcher.mjs
CHANGED
|
@@ -616,6 +616,13 @@ export function selectPlatformPackage({
|
|
|
616
616
|
}
|
|
617
617
|
|
|
618
618
|
export function translateArguments(arguments_) {
|
|
619
|
+
if (
|
|
620
|
+
arguments_.length === 2 &&
|
|
621
|
+
arguments_[0] === "setup" &&
|
|
622
|
+
arguments_[1] === "claude-code"
|
|
623
|
+
) {
|
|
624
|
+
return ["setup", "claude"];
|
|
625
|
+
}
|
|
619
626
|
if (arguments_[0] !== "mcp") {
|
|
620
627
|
return [...arguments_];
|
|
621
628
|
}
|
package/lib/update.mjs
CHANGED
|
@@ -23,7 +23,7 @@ const REPAIR_SCHEMA = "mikie.claude-hook-repair.v1";
|
|
|
23
23
|
const TRAJECTORY_RECONCILIATION_SCHEMA = "mikie.trajectory-store-reconciliation.v1";
|
|
24
24
|
const RERUN_COMMAND = "npx -y @getmikie/cli@latest update";
|
|
25
25
|
const MAX_COMMAND_OUTPUT_BYTES = 1024 * 1024;
|
|
26
|
-
const DEFAULT_COMMAND_TIMEOUT_MS =
|
|
26
|
+
const DEFAULT_COMMAND_TIMEOUT_MS = 120_000;
|
|
27
27
|
const TRANSACTION_SCHEMA = "mikie.npm-update-transaction.v1";
|
|
28
28
|
const LOCK_SCHEMA = "mikie.npm-update-lock.v1";
|
|
29
29
|
const MAX_TRANSACTION_TREE_ENTRIES = 16_384;
|
|
@@ -935,7 +935,15 @@ export function createCommandAdapter({
|
|
|
935
935
|
? environmentNpmCli
|
|
936
936
|
: path.join(path.dirname(nodeExecutable), "node_modules", "npm", "bin", "npm-cli.js"));
|
|
937
937
|
return {
|
|
938
|
-
run(
|
|
938
|
+
run(
|
|
939
|
+
executable,
|
|
940
|
+
args,
|
|
941
|
+
{
|
|
942
|
+
shell = false,
|
|
943
|
+
environment: commandEnvironment = {},
|
|
944
|
+
timeoutMs = commandTimeoutMs,
|
|
945
|
+
} = {},
|
|
946
|
+
) {
|
|
939
947
|
if (
|
|
940
948
|
shell !== false ||
|
|
941
949
|
!Array.isArray(args) ||
|
|
@@ -945,6 +953,9 @@ export function createCommandAdapter({
|
|
|
945
953
|
) {
|
|
946
954
|
throw new Error("Mikie update commands require argument arrays with shell disabled");
|
|
947
955
|
}
|
|
956
|
+
if (!Number.isInteger(timeoutMs) || timeoutMs <= 0) {
|
|
957
|
+
throw new Error("Mikie update command timeout is invalid");
|
|
958
|
+
}
|
|
948
959
|
return new Promise((resolve, reject) => {
|
|
949
960
|
const stdout = [];
|
|
950
961
|
const stderr = [];
|
|
@@ -970,7 +981,7 @@ export function createCommandAdapter({
|
|
|
970
981
|
// The child may already have exited.
|
|
971
982
|
}
|
|
972
983
|
reject(new Error("Mikie update command timed out"));
|
|
973
|
-
},
|
|
984
|
+
}, timeoutMs);
|
|
974
985
|
const finish = (callback) => {
|
|
975
986
|
if (settled) return false;
|
|
976
987
|
settled = true;
|
|
@@ -1041,11 +1052,19 @@ export function createRegistryAdapter({
|
|
|
1041
1052
|
return {
|
|
1042
1053
|
async resolveExactCompatibleVersion({ packageName, nodeVersion }) {
|
|
1043
1054
|
const deadline = now() + resolutionTimeoutMs;
|
|
1044
|
-
const
|
|
1045
|
-
|
|
1055
|
+
const runWithinDeadline = async (args) => {
|
|
1056
|
+
const timeoutMs = deadline - now();
|
|
1057
|
+
if (timeoutMs <= 0) return null;
|
|
1058
|
+
return commands.run(npmExecutable, args, {
|
|
1059
|
+
shell: false,
|
|
1060
|
+
capture: true,
|
|
1061
|
+
timeoutMs,
|
|
1062
|
+
});
|
|
1063
|
+
};
|
|
1064
|
+
const versionsResponse = await runWithinDeadline(
|
|
1046
1065
|
["view", packageName, "versions", "--json", "--registry", registryUrl],
|
|
1047
|
-
{ shell: false, capture: true },
|
|
1048
1066
|
);
|
|
1067
|
+
if (versionsResponse === null) return { public: false, compatible: false };
|
|
1049
1068
|
if (versionsResponse.code !== 0) return { public: false, compatible: false };
|
|
1050
1069
|
let published;
|
|
1051
1070
|
try {
|
|
@@ -1059,8 +1078,7 @@ export function createRegistryAdapter({
|
|
|
1059
1078
|
}
|
|
1060
1079
|
for (const version of published.slice(0, 64)) {
|
|
1061
1080
|
if (now() >= deadline) break;
|
|
1062
|
-
const response = await
|
|
1063
|
-
npmExecutable,
|
|
1081
|
+
const response = await runWithinDeadline(
|
|
1064
1082
|
[
|
|
1065
1083
|
"view",
|
|
1066
1084
|
`${packageName}@${version}`,
|
|
@@ -1070,8 +1088,8 @@ export function createRegistryAdapter({
|
|
|
1070
1088
|
"--registry",
|
|
1071
1089
|
registryUrl,
|
|
1072
1090
|
],
|
|
1073
|
-
{ shell: false, capture: true },
|
|
1074
1091
|
);
|
|
1092
|
+
if (response === null) break;
|
|
1075
1093
|
if (response.code !== 0) continue;
|
|
1076
1094
|
let metadata;
|
|
1077
1095
|
try {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@getmikie/cli",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.113",
|
|
4
4
|
"description": "Native Mikie relay launcher for MCP clients",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"repository": {
|
|
@@ -24,10 +24,10 @@
|
|
|
24
24
|
"node": ">=22"
|
|
25
25
|
},
|
|
26
26
|
"optionalDependencies": {
|
|
27
|
-
"@getmikie/darwin-arm64": "1.1.
|
|
28
|
-
"@getmikie/darwin-x64": "1.1.
|
|
29
|
-
"@getmikie/linux-x64-gnu": "1.1.
|
|
30
|
-
"@getmikie/win32-x64": "1.1.
|
|
27
|
+
"@getmikie/darwin-arm64": "1.1.113",
|
|
28
|
+
"@getmikie/darwin-x64": "1.1.113",
|
|
29
|
+
"@getmikie/linux-x64-gnu": "1.1.113",
|
|
30
|
+
"@getmikie/win32-x64": "1.1.113"
|
|
31
31
|
},
|
|
32
32
|
"publishConfig": {
|
|
33
33
|
"access": "public",
|