@hasna/machines 0.0.31 → 0.0.32
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/index.js +25 -3
- package/dist/commands/apps.d.ts.map +1 -1
- package/dist/commands/install-claude.d.ts.map +1 -1
- package/dist/commands/install-tailscale.d.ts.map +1 -1
- package/dist/commands/setup.d.ts.map +1 -1
- package/dist/commands/sync.d.ts.map +1 -1
- package/dist/index.js +25 -3
- package/dist/mcp/index.js +25 -3
- package/package.json +1 -1
package/dist/cli/index.js
CHANGED
|
@@ -8907,6 +8907,9 @@ function buildSetupPlan(machineId) {
|
|
|
8907
8907
|
const manifest = readManifest();
|
|
8908
8908
|
const currentMachineId = getLocalMachineId();
|
|
8909
8909
|
const selected = machineId ? manifest.machines.find((machine) => machine.id === machineId) : manifest.machines.find((machine) => machine.id === currentMachineId);
|
|
8910
|
+
if (machineId && !selected) {
|
|
8911
|
+
throw new Error(`Machine not found in manifest: ${machineId}`);
|
|
8912
|
+
}
|
|
8910
8913
|
const target = selected || {
|
|
8911
8914
|
id: currentMachineId,
|
|
8912
8915
|
platform: "linux",
|
|
@@ -9288,7 +9291,14 @@ function buildAppSteps(machine) {
|
|
|
9288
9291
|
}));
|
|
9289
9292
|
}
|
|
9290
9293
|
function resolveMachine(machineId) {
|
|
9291
|
-
|
|
9294
|
+
if (!machineId)
|
|
9295
|
+
return detectCurrentMachineManifest();
|
|
9296
|
+
return getManifestMachine(machineId) || {
|
|
9297
|
+
id: machineId,
|
|
9298
|
+
platform: "linux",
|
|
9299
|
+
workspacePath: "",
|
|
9300
|
+
apps: []
|
|
9301
|
+
};
|
|
9292
9302
|
}
|
|
9293
9303
|
function parseProbeOutput(app, machine, stdout) {
|
|
9294
9304
|
const lines = stdout.trim().split(`
|
|
@@ -9393,7 +9403,13 @@ function buildInstallSteps(machine, tools) {
|
|
|
9393
9403
|
}));
|
|
9394
9404
|
}
|
|
9395
9405
|
function resolveMachine2(machineId) {
|
|
9396
|
-
|
|
9406
|
+
if (!machineId)
|
|
9407
|
+
return detectCurrentMachineManifest();
|
|
9408
|
+
return getManifestMachine(machineId) || {
|
|
9409
|
+
id: machineId,
|
|
9410
|
+
platform: "linux",
|
|
9411
|
+
workspacePath: ""
|
|
9412
|
+
};
|
|
9397
9413
|
}
|
|
9398
9414
|
function buildProbeCommand(tool) {
|
|
9399
9415
|
const binary = getToolBinary(tool);
|
|
@@ -9494,7 +9510,10 @@ function buildInstallSteps2(machine) {
|
|
|
9494
9510
|
];
|
|
9495
9511
|
}
|
|
9496
9512
|
function buildTailscaleInstallPlan(machineId) {
|
|
9497
|
-
const machine =
|
|
9513
|
+
const machine = machineId ? getManifestMachine(machineId) : detectCurrentMachineManifest();
|
|
9514
|
+
if (!machine) {
|
|
9515
|
+
throw new Error(`Machine not found in manifest: ${machineId}`);
|
|
9516
|
+
}
|
|
9498
9517
|
return {
|
|
9499
9518
|
machineId: machine.id,
|
|
9500
9519
|
mode: "plan",
|
|
@@ -10625,6 +10644,9 @@ function buildSyncPlan(machineId, runner = runMachineCommand) {
|
|
|
10625
10644
|
const manifest = readManifest();
|
|
10626
10645
|
const currentMachineId = getLocalMachineId();
|
|
10627
10646
|
const selected = machineId ? manifest.machines.find((machine) => machine.id === machineId) : manifest.machines.find((machine) => machine.id === currentMachineId);
|
|
10647
|
+
if (machineId && !selected) {
|
|
10648
|
+
throw new Error(`Machine not found in manifest: ${machineId}`);
|
|
10649
|
+
}
|
|
10628
10650
|
const target = selected || {
|
|
10629
10651
|
id: currentMachineId,
|
|
10630
10652
|
platform: "linux",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"apps.d.ts","sourceRoot":"","sources":["../../src/commands/apps.ts"],"names":[],"mappings":"AACA,OAAO,EAAmD,KAAK,oBAAoB,EAAE,MAAM,cAAc,CAAC;AAC1G,OAAO,KAAK,EACV,cAAc,EACd,gBAAgB,EAGhB,eAAe,EACf,WAAW,EAEZ,MAAM,aAAa,CAAC;
|
|
1
|
+
{"version":3,"file":"apps.d.ts","sourceRoot":"","sources":["../../src/commands/apps.ts"],"names":[],"mappings":"AACA,OAAO,EAAmD,KAAK,oBAAoB,EAAE,MAAM,cAAc,CAAC;AAC1G,OAAO,KAAK,EACV,cAAc,EACd,gBAAgB,EAGhB,eAAe,EACf,WAAW,EAEZ,MAAM,aAAa,CAAC;AAqGrB,wBAAgB,QAAQ,CAAC,SAAS,CAAC,EAAE,MAAM,GAAG;IAAE,SAAS,EAAE,MAAM,CAAC;IAAC,IAAI,EAAE,eAAe,EAAE,CAAA;CAAE,CAM3F;AAED,wBAAgB,aAAa,CAAC,SAAS,CAAC,EAAE,MAAM,GAAG,WAAW,CAQ7D;AAED,wBAAgB,aAAa,CAAC,SAAS,CAAC,EAAE,MAAM,EAAE,MAAM,GAAE,oBAAwC,GAAG,gBAAgB,CAYpH;AAED,wBAAgB,QAAQ,CAAC,SAAS,CAAC,EAAE,MAAM,EAAE,MAAM,GAAE,oBAAwC,GAAG,cAAc,CAO7G;AAED,wBAAgB,cAAc,CAC5B,SAAS,CAAC,EAAE,MAAM,EAClB,OAAO,GAAE;IAAE,KAAK,CAAC,EAAE,OAAO,CAAC;IAAC,GAAG,CAAC,EAAE,OAAO,CAAA;CAAO,EAChD,MAAM,GAAE,oBAAwC,GAC/C,WAAW,CAmBb"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"install-claude.d.ts","sourceRoot":"","sources":["../../src/commands/install-claude.ts"],"names":[],"mappings":"AACA,OAAO,EAAmD,KAAK,oBAAoB,EAAE,MAAM,cAAc,CAAC;AAC1G,OAAO,KAAK,EAAE,mBAAmB,EAAE,qBAAqB,EAAkC,WAAW,EAAa,MAAM,aAAa,CAAC;AAEtI,QAAA,MAAM,eAAe;;;;CAIX,CAAC;AAQX,MAAM,MAAM,SAAS,GAAG,MAAM,OAAO,eAAe,CAAC;
|
|
1
|
+
{"version":3,"file":"install-claude.d.ts","sourceRoot":"","sources":["../../src/commands/install-claude.ts"],"names":[],"mappings":"AACA,OAAO,EAAmD,KAAK,oBAAoB,EAAE,MAAM,cAAc,CAAC;AAC1G,OAAO,KAAK,EAAE,mBAAmB,EAAE,qBAAqB,EAAkC,WAAW,EAAa,MAAM,aAAa,CAAC;AAEtI,QAAA,MAAM,eAAe;;;;CAIX,CAAC;AAQX,MAAM,MAAM,SAAS,GAAG,MAAM,OAAO,eAAe,CAAC;AAkDrD,wBAAgB,sBAAsB,CAAC,SAAS,CAAC,EAAE,MAAM,EAAE,KAAK,CAAC,EAAE,MAAM,EAAE,GAAG,WAAW,CAQxF;AAED,wBAAgB,kBAAkB,CAChC,SAAS,CAAC,EAAE,MAAM,EAClB,KAAK,CAAC,EAAE,MAAM,EAAE,EAChB,MAAM,GAAE,oBAAwC,GAC/C,qBAAqB,CAYvB;AAED,wBAAgB,aAAa,CAC3B,SAAS,CAAC,EAAE,MAAM,EAClB,KAAK,CAAC,EAAE,MAAM,EAAE,EAChB,MAAM,GAAE,oBAAwC,GAC/C,mBAAmB,CAOrB;AAED,wBAAgB,gBAAgB,CAC9B,SAAS,CAAC,EAAE,MAAM,EAClB,KAAK,CAAC,EAAE,MAAM,EAAE,EAChB,OAAO,GAAE;IAAE,KAAK,CAAC,EAAE,OAAO,CAAC;IAAC,GAAG,CAAC,EAAE,OAAO,CAAA;CAAO,EAChD,MAAM,GAAE,oBAAwC,GAC/C,WAAW,CAmBb"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"install-tailscale.d.ts","sourceRoot":"","sources":["../../src/commands/install-tailscale.ts"],"names":[],"mappings":"AACA,OAAO,EAAmD,KAAK,oBAAoB,EAAE,MAAM,cAAc,CAAC;AAC1G,OAAO,KAAK,EAAmB,WAAW,EAAa,MAAM,aAAa,CAAC;AAoC3E,wBAAgB,yBAAyB,CAAC,SAAS,CAAC,EAAE,MAAM,GAAG,WAAW,
|
|
1
|
+
{"version":3,"file":"install-tailscale.d.ts","sourceRoot":"","sources":["../../src/commands/install-tailscale.ts"],"names":[],"mappings":"AACA,OAAO,EAAmD,KAAK,oBAAoB,EAAE,MAAM,cAAc,CAAC;AAC1G,OAAO,KAAK,EAAmB,WAAW,EAAa,MAAM,aAAa,CAAC;AAoC3E,wBAAgB,yBAAyB,CAAC,SAAS,CAAC,EAAE,MAAM,GAAG,WAAW,CAWzE;AAED,wBAAgB,mBAAmB,CACjC,SAAS,CAAC,EAAE,MAAM,EAClB,OAAO,GAAE;IAAE,KAAK,CAAC,EAAE,OAAO,CAAC;IAAC,GAAG,CAAC,EAAE,OAAO,CAAA;CAAO,EAChD,MAAM,GAAE,oBAAwC,GAC/C,WAAW,CAmBb"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"setup.d.ts","sourceRoot":"","sources":["../../src/commands/setup.ts"],"names":[],"mappings":"AAGA,OAAO,EAAoD,KAAK,oBAAoB,EAAE,MAAM,cAAc,CAAC;AAC3G,OAAO,KAAK,EAAmB,WAAW,EAAa,MAAM,aAAa,CAAC;AAsE3E,wBAAgB,cAAc,CAAC,SAAS,CAAC,EAAE,MAAM,GAAG,WAAW,
|
|
1
|
+
{"version":3,"file":"setup.d.ts","sourceRoot":"","sources":["../../src/commands/setup.ts"],"names":[],"mappings":"AAGA,OAAO,EAAoD,KAAK,oBAAoB,EAAE,MAAM,cAAc,CAAC;AAC3G,OAAO,KAAK,EAAmB,WAAW,EAAa,MAAM,aAAa,CAAC;AAsE3E,wBAAgB,cAAc,CAAC,SAAS,CAAC,EAAE,MAAM,GAAG,WAAW,CAyB9D;AAED,wBAAgB,QAAQ,CACtB,SAAS,CAAC,EAAE,MAAM,EAClB,OAAO,GAAE;IAAE,KAAK,CAAC,EAAE,OAAO,CAAC;IAAC,GAAG,CAAC,EAAE,OAAO,CAAA;CAAO,EAChD,MAAM,GAAE,oBAAwC,GAC/C,WAAW,CAmCb"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sync.d.ts","sourceRoot":"","sources":["../../src/commands/sync.ts"],"names":[],"mappings":"AAMA,OAAO,EAA2E,KAAK,oBAAoB,EAAE,MAAM,cAAc,CAAC;AAClI,OAAO,KAAK,EAA+B,UAAU,EAAE,MAAM,aAAa,CAAC;AAqF3E,wBAAgB,aAAa,CAAC,SAAS,CAAC,EAAE,MAAM,EAAE,MAAM,GAAE,oBAAwC,GAAG,UAAU,
|
|
1
|
+
{"version":3,"file":"sync.d.ts","sourceRoot":"","sources":["../../src/commands/sync.ts"],"names":[],"mappings":"AAMA,OAAO,EAA2E,KAAK,oBAAoB,EAAE,MAAM,cAAc,CAAC;AAClI,OAAO,KAAK,EAA+B,UAAU,EAAE,MAAM,aAAa,CAAC;AAqF3E,wBAAgB,aAAa,CAAC,SAAS,CAAC,EAAE,MAAM,EAAE,MAAM,GAAE,oBAAwC,GAAG,UAAU,CA4B9G;AAwBD,wBAAgB,OAAO,CACrB,SAAS,CAAC,EAAE,MAAM,EAClB,OAAO,GAAE;IAAE,KAAK,CAAC,EAAE,OAAO,CAAC;IAAC,GAAG,CAAC,EAAE,OAAO,CAAA;CAAO,EAChD,MAAM,GAAE,oBAAwC,GAC/C,UAAU,CAwCZ"}
|
package/dist/index.js
CHANGED
|
@@ -12645,7 +12645,14 @@ function buildAppSteps(machine) {
|
|
|
12645
12645
|
}));
|
|
12646
12646
|
}
|
|
12647
12647
|
function resolveMachine(machineId) {
|
|
12648
|
-
|
|
12648
|
+
if (!machineId)
|
|
12649
|
+
return detectCurrentMachineManifest();
|
|
12650
|
+
return getManifestMachine(machineId) || {
|
|
12651
|
+
id: machineId,
|
|
12652
|
+
platform: "linux",
|
|
12653
|
+
workspacePath: "",
|
|
12654
|
+
apps: []
|
|
12655
|
+
};
|
|
12649
12656
|
}
|
|
12650
12657
|
function parseProbeOutput(app, machine, stdout) {
|
|
12651
12658
|
const lines = stdout.trim().split(`
|
|
@@ -12995,7 +13002,13 @@ function buildInstallSteps(machine, tools) {
|
|
|
12995
13002
|
}));
|
|
12996
13003
|
}
|
|
12997
13004
|
function resolveMachine2(machineId) {
|
|
12998
|
-
|
|
13005
|
+
if (!machineId)
|
|
13006
|
+
return detectCurrentMachineManifest();
|
|
13007
|
+
return getManifestMachine(machineId) || {
|
|
13008
|
+
id: machineId,
|
|
13009
|
+
platform: "linux",
|
|
13010
|
+
workspacePath: ""
|
|
13011
|
+
};
|
|
12999
13012
|
}
|
|
13000
13013
|
function buildProbeCommand(tool) {
|
|
13001
13014
|
const binary = getToolBinary(tool);
|
|
@@ -13095,7 +13108,10 @@ function buildInstallSteps2(machine) {
|
|
|
13095
13108
|
];
|
|
13096
13109
|
}
|
|
13097
13110
|
function buildTailscaleInstallPlan(machineId) {
|
|
13098
|
-
const machine =
|
|
13111
|
+
const machine = machineId ? getManifestMachine(machineId) : detectCurrentMachineManifest();
|
|
13112
|
+
if (!machine) {
|
|
13113
|
+
throw new Error(`Machine not found in manifest: ${machineId}`);
|
|
13114
|
+
}
|
|
13099
13115
|
return {
|
|
13100
13116
|
machineId: machine.id,
|
|
13101
13117
|
mode: "plan",
|
|
@@ -14476,6 +14492,9 @@ function buildSetupPlan(machineId) {
|
|
|
14476
14492
|
const manifest = readManifest();
|
|
14477
14493
|
const currentMachineId = getLocalMachineId();
|
|
14478
14494
|
const selected = machineId ? manifest.machines.find((machine) => machine.id === machineId) : manifest.machines.find((machine) => machine.id === currentMachineId);
|
|
14495
|
+
if (machineId && !selected) {
|
|
14496
|
+
throw new Error(`Machine not found in manifest: ${machineId}`);
|
|
14497
|
+
}
|
|
14479
14498
|
const target = selected || {
|
|
14480
14499
|
id: currentMachineId,
|
|
14481
14500
|
platform: "linux",
|
|
@@ -14723,6 +14742,9 @@ function buildSyncPlan(machineId, runner = runMachineCommand) {
|
|
|
14723
14742
|
const manifest = readManifest();
|
|
14724
14743
|
const currentMachineId = getLocalMachineId();
|
|
14725
14744
|
const selected = machineId ? manifest.machines.find((machine) => machine.id === machineId) : manifest.machines.find((machine) => machine.id === currentMachineId);
|
|
14745
|
+
if (machineId && !selected) {
|
|
14746
|
+
throw new Error(`Machine not found in manifest: ${machineId}`);
|
|
14747
|
+
}
|
|
14726
14748
|
const target = selected || {
|
|
14727
14749
|
id: currentMachineId,
|
|
14728
14750
|
platform: "linux",
|
package/dist/mcp/index.js
CHANGED
|
@@ -5866,7 +5866,14 @@ function buildAppSteps(machine) {
|
|
|
5866
5866
|
}));
|
|
5867
5867
|
}
|
|
5868
5868
|
function resolveMachine(machineId) {
|
|
5869
|
-
|
|
5869
|
+
if (!machineId)
|
|
5870
|
+
return detectCurrentMachineManifest();
|
|
5871
|
+
return getManifestMachine(machineId) || {
|
|
5872
|
+
id: machineId,
|
|
5873
|
+
platform: "linux",
|
|
5874
|
+
workspacePath: "",
|
|
5875
|
+
apps: []
|
|
5876
|
+
};
|
|
5870
5877
|
}
|
|
5871
5878
|
function parseProbeOutput(app, machine, stdout) {
|
|
5872
5879
|
const lines = stdout.trim().split(`
|
|
@@ -6187,7 +6194,13 @@ function buildInstallSteps(machine, tools) {
|
|
|
6187
6194
|
}));
|
|
6188
6195
|
}
|
|
6189
6196
|
function resolveMachine2(machineId) {
|
|
6190
|
-
|
|
6197
|
+
if (!machineId)
|
|
6198
|
+
return detectCurrentMachineManifest();
|
|
6199
|
+
return getManifestMachine(machineId) || {
|
|
6200
|
+
id: machineId,
|
|
6201
|
+
platform: "linux",
|
|
6202
|
+
workspacePath: ""
|
|
6203
|
+
};
|
|
6191
6204
|
}
|
|
6192
6205
|
function buildProbeCommand(tool) {
|
|
6193
6206
|
const binary = getToolBinary(tool);
|
|
@@ -6288,7 +6301,10 @@ function buildInstallSteps2(machine) {
|
|
|
6288
6301
|
];
|
|
6289
6302
|
}
|
|
6290
6303
|
function buildTailscaleInstallPlan(machineId) {
|
|
6291
|
-
const machine =
|
|
6304
|
+
const machine = machineId ? getManifestMachine(machineId) : detectCurrentMachineManifest();
|
|
6305
|
+
if (!machine) {
|
|
6306
|
+
throw new Error(`Machine not found in manifest: ${machineId}`);
|
|
6307
|
+
}
|
|
6292
6308
|
return {
|
|
6293
6309
|
machineId: machine.id,
|
|
6294
6310
|
mode: "plan",
|
|
@@ -6961,6 +6977,9 @@ function buildSetupPlan(machineId) {
|
|
|
6961
6977
|
const manifest = readManifest();
|
|
6962
6978
|
const currentMachineId = getLocalMachineId();
|
|
6963
6979
|
const selected = machineId ? manifest.machines.find((machine) => machine.id === machineId) : manifest.machines.find((machine) => machine.id === currentMachineId);
|
|
6980
|
+
if (machineId && !selected) {
|
|
6981
|
+
throw new Error(`Machine not found in manifest: ${machineId}`);
|
|
6982
|
+
}
|
|
6964
6983
|
const target = selected || {
|
|
6965
6984
|
id: currentMachineId,
|
|
6966
6985
|
platform: "linux",
|
|
@@ -7088,6 +7107,9 @@ function buildSyncPlan(machineId, runner = runMachineCommand) {
|
|
|
7088
7107
|
const manifest = readManifest();
|
|
7089
7108
|
const currentMachineId = getLocalMachineId();
|
|
7090
7109
|
const selected = machineId ? manifest.machines.find((machine) => machine.id === machineId) : manifest.machines.find((machine) => machine.id === currentMachineId);
|
|
7110
|
+
if (machineId && !selected) {
|
|
7111
|
+
throw new Error(`Machine not found in manifest: ${machineId}`);
|
|
7112
|
+
}
|
|
7091
7113
|
const target = selected || {
|
|
7092
7114
|
id: currentMachineId,
|
|
7093
7115
|
platform: "linux",
|