@dxos/cli 0.5.2 → 0.5.3-main.0a95b55
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/src/commands/agent/invitations.js +3 -5
- package/dist/src/commands/agent/invitations.js.map +1 -1
- package/dist/src/commands/agent/start.js +1 -1
- package/dist/src/commands/agent/start.js.map +1 -1
- package/dist/src/commands/agent/status.js +2 -4
- package/dist/src/commands/agent/status.js.map +1 -1
- package/dist/src/commands/app/open.js +1 -1
- package/dist/src/commands/app/open.js.map +1 -1
- package/dist/src/commands/function/dev.d.ts +1 -1
- package/dist/src/commands/function/dev.d.ts.map +1 -1
- package/dist/src/commands/function/dev.js +20 -12
- package/dist/src/commands/function/dev.js.map +1 -1
- package/dist/src/commands/function/list.d.ts.map +1 -1
- package/dist/src/commands/function/list.js +13 -8
- package/dist/src/commands/function/list.js.map +1 -1
- package/dist/src/commands/halo/keys.d.ts +7 -0
- package/dist/src/commands/halo/keys.d.ts.map +1 -0
- package/dist/src/commands/halo/keys.js +17 -0
- package/dist/src/commands/halo/keys.js.map +1 -0
- package/dist/src/commands/halo/share.d.ts +1 -1
- package/dist/src/commands/halo/share.d.ts.map +1 -1
- package/dist/src/commands/halo/share.js +7 -9
- package/dist/src/commands/halo/share.js.map +1 -1
- package/dist/src/commands/space/share.d.ts +2 -3
- package/dist/src/commands/space/share.d.ts.map +1 -1
- package/dist/src/commands/space/share.js +3 -14
- package/dist/src/commands/space/share.js.map +1 -1
- package/dist/src/errors.d.ts +1 -1
- package/dist/src/errors.d.ts.map +1 -1
- package/dist/src/errors.js +4 -4
- package/dist/src/errors.js.map +1 -1
- package/dist/src/hooks/command-not-found.js +1 -1
- package/dist/src/hooks/command-not-found.js.map +1 -1
- package/dist/src/util/spaces.js +1 -1
- package/dist/src/util/spaces.js.map +1 -1
- package/oclif.manifest.json +210 -219
- package/package.json +26 -23
- package/dist/src/commands/function/exec.d.ts +0 -13
- package/dist/src/commands/function/exec.d.ts.map +0 -1
- package/dist/src/commands/function/exec.js +0 -48
- package/dist/src/commands/function/exec.js.map +0 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dxos/cli",
|
|
3
|
-
"version": "0.5.
|
|
3
|
+
"version": "0.5.3-main.0a95b55",
|
|
4
4
|
"description": "DXOS CLI",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"dxos",
|
|
@@ -49,28 +49,28 @@
|
|
|
49
49
|
"uuid": "^8.3.2",
|
|
50
50
|
"ws": "^8.14.2",
|
|
51
51
|
"wtfnode": "^0.9.1",
|
|
52
|
-
"@dxos/agent": "0.5.
|
|
53
|
-
"@dxos/async": "0.5.
|
|
54
|
-
"@dxos/
|
|
55
|
-
"@dxos/client
|
|
56
|
-
"@dxos/
|
|
57
|
-
"@dxos/client-
|
|
58
|
-
"@dxos/config": "0.5.
|
|
59
|
-
"@dxos/context": "0.5.
|
|
60
|
-
"@dxos/debug": "0.5.
|
|
61
|
-
"@dxos/functions": "0.5.
|
|
62
|
-
"@dxos/hello-template": "0.5.
|
|
63
|
-
"@dxos/
|
|
64
|
-
"@dxos/network-manager": "0.5.
|
|
65
|
-
"@dxos/observability": "0.5.
|
|
66
|
-
"@dxos/
|
|
67
|
-
"@dxos/
|
|
68
|
-
"@dxos/
|
|
69
|
-
"@dxos/
|
|
70
|
-
"@dxos/random": "0.5.
|
|
71
|
-
"@dxos/rpc": "0.5.
|
|
72
|
-
"@dxos/util": "0.5.
|
|
73
|
-
"@dxos/tasks-template": "0.5.
|
|
52
|
+
"@dxos/agent": "0.5.3-main.0a95b55",
|
|
53
|
+
"@dxos/async": "0.5.3-main.0a95b55",
|
|
54
|
+
"@dxos/bare-template": "0.5.3-main.0a95b55",
|
|
55
|
+
"@dxos/client": "0.5.3-main.0a95b55",
|
|
56
|
+
"@dxos/client-protocol": "0.5.3-main.0a95b55",
|
|
57
|
+
"@dxos/client-services": "0.5.3-main.0a95b55",
|
|
58
|
+
"@dxos/config": "0.5.3-main.0a95b55",
|
|
59
|
+
"@dxos/context": "0.5.3-main.0a95b55",
|
|
60
|
+
"@dxos/debug": "0.5.3-main.0a95b55",
|
|
61
|
+
"@dxos/functions": "0.5.3-main.0a95b55",
|
|
62
|
+
"@dxos/hello-template": "0.5.3-main.0a95b55",
|
|
63
|
+
"@dxos/log": "0.5.3-main.0a95b55",
|
|
64
|
+
"@dxos/network-manager": "0.5.3-main.0a95b55",
|
|
65
|
+
"@dxos/observability": "0.5.3-main.0a95b55",
|
|
66
|
+
"@dxos/invariant": "0.5.3-main.0a95b55",
|
|
67
|
+
"@dxos/protocols": "0.5.3-main.0a95b55",
|
|
68
|
+
"@dxos/process": "0.5.3-main.0a95b55",
|
|
69
|
+
"@dxos/plate": "0.5.3-main.0a95b55",
|
|
70
|
+
"@dxos/random": "0.5.3-main.0a95b55",
|
|
71
|
+
"@dxos/rpc": "0.5.3-main.0a95b55",
|
|
72
|
+
"@dxos/util": "0.5.3-main.0a95b55",
|
|
73
|
+
"@dxos/tasks-template": "0.5.3-main.0a95b55"
|
|
74
74
|
},
|
|
75
75
|
"devDependencies": {
|
|
76
76
|
"@oclif/test": "^3.2.15",
|
|
@@ -109,6 +109,9 @@
|
|
|
109
109
|
"plugins": [
|
|
110
110
|
"@oclif/plugin-help"
|
|
111
111
|
],
|
|
112
|
+
"devPlugins": [
|
|
113
|
+
"@oclif/plugin-help"
|
|
114
|
+
],
|
|
112
115
|
"helpClass": "./dist/src/help",
|
|
113
116
|
"topicSeparator": " ",
|
|
114
117
|
"topics": {
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { BaseCommand } from '../../base-command';
|
|
2
|
-
/**
|
|
3
|
-
* @deprecated
|
|
4
|
-
*/
|
|
5
|
-
export default class Exec extends BaseCommand<typeof Exec> {
|
|
6
|
-
static enableJsonFlag: boolean;
|
|
7
|
-
static description: string;
|
|
8
|
-
static args: {
|
|
9
|
-
name: import("@oclif/core/lib/interfaces").Arg<string, Record<string, unknown>>;
|
|
10
|
-
};
|
|
11
|
-
run(): Promise<any>;
|
|
12
|
-
}
|
|
13
|
-
//# sourceMappingURL=exec.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"exec.d.ts","sourceRoot":"","sources":["../../../../src/commands/function/exec.ts"],"names":[],"mappings":"AAYA,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AAEjD;;GAEG;AACH,MAAM,CAAC,OAAO,OAAO,IAAK,SAAQ,WAAW,CAAC,OAAO,IAAI,CAAC;IACxD,OAAgB,cAAc,UAAQ;IACtC,OAAgB,WAAW,SAAsB;IAEjD,OAAgB,IAAI;;MAElB;IAEI,GAAG,IAAI,OAAO,CAAC,GAAG,CAAC;CA8B1B"}
|
|
@@ -1,48 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
//
|
|
3
|
-
// Copyright 2023 DXOS.org
|
|
4
|
-
//
|
|
5
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
const core_1 = require("@oclif/core");
|
|
7
|
-
const js_yaml_1 = require("js-yaml");
|
|
8
|
-
const promises_1 = require("node:fs/promises");
|
|
9
|
-
const node_path_1 = require("node:path");
|
|
10
|
-
const config_1 = require("@dxos/config");
|
|
11
|
-
const base_command_1 = require("../../base-command");
|
|
12
|
-
/**
|
|
13
|
-
* @deprecated
|
|
14
|
-
*/
|
|
15
|
-
class Exec extends base_command_1.BaseCommand {
|
|
16
|
-
async run() {
|
|
17
|
-
return await this.execWithClient(async (client) => {
|
|
18
|
-
var _a, _b, _c, _d, _e, _f;
|
|
19
|
-
// TODO(dmaretskyi): Move into system service?
|
|
20
|
-
const config = new config_1.Config(JSON.parse((await client.services.services.DevtoolsHost.getConfig()).config));
|
|
21
|
-
const functionsConfig = (_c = (_b = (_a = config.values.runtime) === null || _a === void 0 ? void 0 : _a.agent) === null || _b === void 0 ? void 0 : _b.plugins) === null || _c === void 0 ? void 0 : _c.find((plugin) => plugin.id === 'dxos.org/agent/plugin/functions');
|
|
22
|
-
const file = (_f = (_d = this.flags.manifest) !== null && _d !== void 0 ? _d : (_e = functionsConfig === null || functionsConfig === void 0 ? void 0 : functionsConfig.config) === null || _e === void 0 ? void 0 : _e.manifest) !== null && _f !== void 0 ? _f : (0, node_path_1.join)(process.cwd(), 'functions.yml');
|
|
23
|
-
const { functions } = (0, js_yaml_1.load)(await (0, promises_1.readFile)(file, 'utf8'));
|
|
24
|
-
const fn = functions.find((fn) => fn.id === this.args.name);
|
|
25
|
-
if (!fn) {
|
|
26
|
-
this.warn(`Function not found: ${this.args.name}`);
|
|
27
|
-
return null;
|
|
28
|
-
}
|
|
29
|
-
const { handler } = fn;
|
|
30
|
-
// TODO(burdon): Get endpoint.
|
|
31
|
-
const url = `http:/localhost:7100/dev/${handler}`;
|
|
32
|
-
this.log(`Calling: ${url}`);
|
|
33
|
-
const { status, statusText } = await fetch(url, {
|
|
34
|
-
method: 'POST',
|
|
35
|
-
});
|
|
36
|
-
if (status !== 200) {
|
|
37
|
-
this.warn(`Error(${status}): ${statusText}`);
|
|
38
|
-
}
|
|
39
|
-
});
|
|
40
|
-
}
|
|
41
|
-
}
|
|
42
|
-
Exec.enableJsonFlag = true;
|
|
43
|
-
Exec.description = 'Invoke function.';
|
|
44
|
-
Exec.args = {
|
|
45
|
-
name: core_1.Args.string({ required: true, description: 'Function name.' }),
|
|
46
|
-
};
|
|
47
|
-
exports.default = Exec;
|
|
48
|
-
//# sourceMappingURL=exec.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"exec.js","sourceRoot":"","sources":["../../../../src/commands/function/exec.ts"],"names":[],"mappings":";AAAA,EAAE;AACF,0BAA0B;AAC1B,EAAE;;AAEF,sCAAmC;AACnC,qCAA+B;AAC/B,+CAA4C;AAC5C,yCAAiC;AAEjC,yCAAsC;AAGtC,qDAAiD;AAEjD;;GAEG;AACH,MAAqB,IAAK,SAAQ,0BAAwB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