@kevisual/cli 0.1.1 → 0.1.2

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.
@@ -49771,7 +49771,6 @@ class RemoteApp {
49771
49771
  this.emitter.off(event, listener);
49772
49772
  };
49773
49773
  }
49774
- sendData(data) {}
49775
49774
  json(data) {
49776
49775
  this.ws.send(JSON.stringify(data));
49777
49776
  }
@@ -49782,7 +49781,9 @@ class RemoteApp {
49782
49781
  try {
49783
49782
  const data = event.toString();
49784
49783
  const body = JSON.parse(data);
49785
- const message = body.data || {};
49784
+ const bodyData = body?.data;
49785
+ const message = bodyData?.message || {};
49786
+ const context = bodyData?.context || {};
49786
49787
  if (body?.code === 401) {
49787
49788
  console.error("远程应用认证失败,请检查 token 是否正确");
49788
49789
  this.isError = true;
@@ -49800,12 +49801,12 @@ class RemoteApp {
49800
49801
  });
49801
49802
  return;
49802
49803
  }
49803
- const res = await app.call(message);
49804
+ const res = await app.run(message, context);
49804
49805
  remoteApp.json({
49805
49806
  id: body.id,
49806
49807
  data: {
49807
49808
  code: res.code,
49808
- data: res.body,
49809
+ data: res.data,
49809
49810
  message: res.message
49810
49811
  }
49811
49812
  });
@@ -89769,7 +89769,6 @@ class RemoteApp {
89769
89769
  this.emitter.off(event, listener);
89770
89770
  };
89771
89771
  }
89772
- sendData(data) {}
89773
89772
  json(data) {
89774
89773
  this.ws.send(JSON.stringify(data));
89775
89774
  }
@@ -89780,7 +89779,9 @@ class RemoteApp {
89780
89779
  try {
89781
89780
  const data = event.toString();
89782
89781
  const body = JSON.parse(data);
89783
- const message = body.data || {};
89782
+ const bodyData = body?.data;
89783
+ const message = bodyData?.message || {};
89784
+ const context = bodyData?.context || {};
89784
89785
  if (body?.code === 401) {
89785
89786
  console.error("远程应用认证失败,请检查 token 是否正确");
89786
89787
  this.isError = true;
@@ -89798,12 +89799,12 @@ class RemoteApp {
89798
89799
  });
89799
89800
  return;
89800
89801
  }
89801
- const res = await app.call(message);
89802
+ const res = await app.run(message, context);
89802
89803
  remoteApp.json({
89803
89804
  id: body.id,
89804
89805
  data: {
89805
89806
  code: res.code,
89806
- data: res.body,
89807
+ data: res.data,
89807
89808
  message: res.message
89808
89809
  }
89809
89810
  });
package/dist/assistant.js CHANGED
@@ -34901,7 +34901,6 @@ class RemoteApp {
34901
34901
  this.emitter.off(event, listener);
34902
34902
  };
34903
34903
  }
34904
- sendData(data) {}
34905
34904
  json(data) {
34906
34905
  this.ws.send(JSON.stringify(data));
34907
34906
  }
@@ -34912,7 +34911,9 @@ class RemoteApp {
34912
34911
  try {
34913
34912
  const data = event.toString();
34914
34913
  const body = JSON.parse(data);
34915
- const message = body.data || {};
34914
+ const bodyData = body?.data;
34915
+ const message = bodyData?.message || {};
34916
+ const context = bodyData?.context || {};
34916
34917
  if (body?.code === 401) {
34917
34918
  console.error("远程应用认证失败,请检查 token 是否正确");
34918
34919
  this.isError = true;
@@ -34930,12 +34931,12 @@ class RemoteApp {
34930
34931
  });
34931
34932
  return;
34932
34933
  }
34933
- const res = await app.call(message);
34934
+ const res = await app.run(message, context);
34934
34935
  remoteApp.json({
34935
34936
  id: body.id,
34936
34937
  data: {
34937
34938
  code: res.code,
34938
- data: res.body,
34939
+ data: res.data,
34939
34940
  message: res.message
34940
34941
  }
34941
34942
  });
package/dist/envision.js CHANGED
@@ -22327,8 +22327,8 @@ InitEnv.init();
22327
22327
  var version = useContextKey("version", () => {
22328
22328
  let version2 = "0.0.64";
22329
22329
  try {
22330
- if ("0.1.1")
22331
- version2 = "0.1.1";
22330
+ if ("0.1.2")
22331
+ version2 = "0.1.2";
22332
22332
  } catch (e) {}
22333
22333
  return version2;
22334
22334
  });
@@ -28576,7 +28576,8 @@ var deployLoadFn = async (id, org) => {
28576
28576
  key: "publish",
28577
28577
  data: {
28578
28578
  id,
28579
- username: org
28579
+ username: org,
28580
+ detect: true
28580
28581
  }
28581
28582
  });
28582
28583
  if (res.code === 200) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kevisual/cli",
3
- "version": "0.1.1",
3
+ "version": "0.1.2",
4
4
  "description": "envision 命令行工具",
5
5
  "type": "module",
6
6
  "basename": "/root/cli",
@@ -49,7 +49,7 @@
49
49
  "@kevisual/auth": "^2.0.3",
50
50
  "@kevisual/context": "^0.0.4",
51
51
  "@kevisual/use-config": "^1.0.30",
52
- "@opencode-ai/sdk": "^1.1.49",
52
+ "@opencode-ai/sdk": "^1.1.50",
53
53
  "@types/busboy": "^1.5.4",
54
54
  "busboy": "^1.6.0",
55
55
  "eventemitter3": "^5.0.4",