@flowcore/cli 2.2.1 → 2.3.0
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/CHANGELOG.md +14 -0
- package/README.md +29 -7
- package/dist/commands/apply.d.ts +10 -0
- package/dist/commands/apply.js +27 -0
- package/oclif.manifest.json +41 -1
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -10,6 +10,20 @@
|
|
|
10
10
|
|
|
11
11
|
* added description to start that includes week ([58687a7](https://github.com/flowcore-io/flowcore-cli/commit/58687a7bbb66aaa5d6da26af88e555cbb1e72467))
|
|
12
12
|
|
|
13
|
+
## [2.3.0](https://github.com/flowcore-io/flowcore-cli/compare/v2.2.2...v2.3.0) (2024-02-19)
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
### Features
|
|
17
|
+
|
|
18
|
+
* update `flowcore apply` command to support applying a resource manifest against the Flowcore Platform for multiple files ([74696c2](https://github.com/flowcore-io/flowcore-cli/commit/74696c2fd7da448bff7374656d1657ff3e063305))
|
|
19
|
+
|
|
20
|
+
## [2.2.2](https://github.com/flowcore-io/flowcore-cli/compare/v2.2.1...v2.2.2) (2024-02-16)
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
### Bug Fixes
|
|
24
|
+
|
|
25
|
+
* bumped data core plugin ([3e3c5bc](https://github.com/flowcore-io/flowcore-cli/commit/3e3c5bc6c4ab3437ccece5ec28177fc68b9fe1ff))
|
|
26
|
+
|
|
13
27
|
## [2.2.1](https://github.com/flowcore-io/flowcore-cli/compare/v2.2.0...v2.2.1) (2024-02-16)
|
|
14
28
|
|
|
15
29
|
|
package/README.md
CHANGED
|
@@ -18,7 +18,7 @@ $ npm install -g @flowcore/cli
|
|
|
18
18
|
$ flowcore COMMAND
|
|
19
19
|
running command...
|
|
20
20
|
$ flowcore (--version)
|
|
21
|
-
@flowcore/cli/2.
|
|
21
|
+
@flowcore/cli/2.3.0 linux-x64 node-v20.11.0
|
|
22
22
|
$ flowcore --help [COMMAND]
|
|
23
23
|
USAGE
|
|
24
24
|
$ flowcore COMMAND
|
|
@@ -27,6 +27,7 @@ USAGE
|
|
|
27
27
|
<!-- usagestop -->
|
|
28
28
|
# Commands
|
|
29
29
|
<!-- commands -->
|
|
30
|
+
* [`flowcore apply`](#flowcore-apply)
|
|
30
31
|
* [`flowcore autocomplete [SHELL]`](#flowcore-autocomplete-shell)
|
|
31
32
|
* [`flowcore config set`](#flowcore-config-set)
|
|
32
33
|
* [`flowcore config show`](#flowcore-config-show)
|
|
@@ -47,6 +48,27 @@ USAGE
|
|
|
47
48
|
* [`flowcore version`](#flowcore-version)
|
|
48
49
|
* [`flowcore whoami`](#flowcore-whoami)
|
|
49
50
|
|
|
51
|
+
## `flowcore apply`
|
|
52
|
+
|
|
53
|
+
Apply a resource manifest against the Flowcore Platform
|
|
54
|
+
|
|
55
|
+
```
|
|
56
|
+
USAGE
|
|
57
|
+
$ flowcore apply -f <value> [--profile <value>]
|
|
58
|
+
|
|
59
|
+
FLAGS
|
|
60
|
+
-f, --file=<value>... (required) file to apply
|
|
61
|
+
--profile=<value> Specify the configuration profile to use
|
|
62
|
+
|
|
63
|
+
DESCRIPTION
|
|
64
|
+
Apply a resource manifest against the Flowcore Platform
|
|
65
|
+
|
|
66
|
+
EXAMPLES
|
|
67
|
+
$ flowcore apply -f ./path/to/manifest.yml
|
|
68
|
+
```
|
|
69
|
+
|
|
70
|
+
_See code: [src/commands/apply.ts](https://github.com/flowcore-io/flowcore-cli/blob/v2.3.0/src/commands/apply.ts)_
|
|
71
|
+
|
|
50
72
|
## `flowcore autocomplete [SHELL]`
|
|
51
73
|
|
|
52
74
|
Display autocomplete installation instructions.
|
|
@@ -134,13 +156,13 @@ Apply a manifest configuration for a Data Core to the Flowcore Platform
|
|
|
134
156
|
|
|
135
157
|
```
|
|
136
158
|
USAGE
|
|
137
|
-
$ flowcore data-core apply -f <value>
|
|
159
|
+
$ flowcore data-core apply -f <value> [--profile <value>] [-n <value>] [-t <value>] [-y]
|
|
138
160
|
|
|
139
161
|
FLAGS
|
|
140
|
-
-f, --file=<value
|
|
162
|
+
-f, --file=<value>... (required) file to apply
|
|
141
163
|
-n, --name=<value> name of the data core to apply
|
|
142
|
-
-t, --tenant=<value>
|
|
143
|
-
|
|
164
|
+
-t, --tenant=<value> tenant to apply the data core to, this is the org for your organization, it can be seen in the
|
|
165
|
+
url when accessing your organization
|
|
144
166
|
-y, --yes skip confirmation
|
|
145
167
|
--profile=<value> Specify the configuration profile to use
|
|
146
168
|
|
|
@@ -155,7 +177,7 @@ EXAMPLES
|
|
|
155
177
|
$ cat <<EOF | flowcore data-core apply -f -
|
|
156
178
|
```
|
|
157
179
|
|
|
158
|
-
_See code: [@flowcore/cli-plugin-data-core](https://github.com/flowcore/flowcore-cli-data-core/blob/v1.
|
|
180
|
+
_See code: [@flowcore/cli-plugin-data-core](https://github.com/flowcore/flowcore-cli-data-core/blob/v1.2.0/src/commands/data-core/apply.ts)_
|
|
159
181
|
|
|
160
182
|
## `flowcore help [COMMANDS]`
|
|
161
183
|
|
|
@@ -515,7 +537,7 @@ EXAMPLES
|
|
|
515
537
|
$ flowcore stream https://flowcore.io/<org>/<data core>/<flow type>/[<event type1>,<event type2>,<event type3>].stream -o log -s 3m
|
|
516
538
|
```
|
|
517
539
|
|
|
518
|
-
_See code: [src/commands/stream.ts](https://github.com/flowcore-io/flowcore-cli/blob/v2.
|
|
540
|
+
_See code: [src/commands/stream.ts](https://github.com/flowcore-io/flowcore-cli/blob/v2.3.0/src/commands/stream.ts)_
|
|
519
541
|
|
|
520
542
|
## `flowcore version`
|
|
521
543
|
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { BaseCommand } from "@flowcore/cli-plugin-config";
|
|
2
|
+
export default class Apply extends BaseCommand<typeof Apply> {
|
|
3
|
+
static args: {};
|
|
4
|
+
static description: string;
|
|
5
|
+
static examples: string[];
|
|
6
|
+
static flags: {
|
|
7
|
+
file: import("@oclif/core/lib/interfaces/parser.js").OptionFlag<string[], import("@oclif/core/lib/interfaces/parser.js").CustomOptions>;
|
|
8
|
+
};
|
|
9
|
+
run(): Promise<void>;
|
|
10
|
+
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { BaseCommand } from "@flowcore/cli-plugin-config";
|
|
2
|
+
import { Flags } from '@oclif/core';
|
|
3
|
+
import dayjs from "dayjs";
|
|
4
|
+
import isSameOrBefore from "dayjs/plugin/isSameOrBefore.js";
|
|
5
|
+
import utc from "dayjs/plugin/utc.js";
|
|
6
|
+
dayjs.extend(utc);
|
|
7
|
+
dayjs.extend(isSameOrBefore);
|
|
8
|
+
export default class Apply extends BaseCommand {
|
|
9
|
+
static args = {};
|
|
10
|
+
static description = 'Apply a resource manifest against the Flowcore Platform';
|
|
11
|
+
static examples = [
|
|
12
|
+
'<%= config.bin %> <%= command.id %> -f ./path/to/manifest.yml',
|
|
13
|
+
];
|
|
14
|
+
static flags = {
|
|
15
|
+
file: Flags.string({ char: 'f', description: 'file to apply', multiple: true, required: true }),
|
|
16
|
+
};
|
|
17
|
+
async run() {
|
|
18
|
+
const { flags } = await this.parse(Apply);
|
|
19
|
+
const resources = [
|
|
20
|
+
"data-core",
|
|
21
|
+
];
|
|
22
|
+
for (const resource of resources) {
|
|
23
|
+
// eslint-disable-next-line no-await-in-loop
|
|
24
|
+
await this.config.runCommand(`${resource}:apply`, flags.file.map((file) => `--file=${file}`));
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
}
|
package/oclif.manifest.json
CHANGED
|
@@ -1,5 +1,45 @@
|
|
|
1
1
|
{
|
|
2
2
|
"commands": {
|
|
3
|
+
"apply": {
|
|
4
|
+
"aliases": [],
|
|
5
|
+
"args": {},
|
|
6
|
+
"description": "Apply a resource manifest against the Flowcore Platform",
|
|
7
|
+
"examples": [
|
|
8
|
+
"<%= config.bin %> <%= command.id %> -f ./path/to/manifest.yml"
|
|
9
|
+
],
|
|
10
|
+
"flags": {
|
|
11
|
+
"profile": {
|
|
12
|
+
"description": "Specify the configuration profile to use",
|
|
13
|
+
"name": "profile",
|
|
14
|
+
"hasDynamicHelp": false,
|
|
15
|
+
"multiple": false,
|
|
16
|
+
"type": "option"
|
|
17
|
+
},
|
|
18
|
+
"file": {
|
|
19
|
+
"char": "f",
|
|
20
|
+
"description": "file to apply",
|
|
21
|
+
"name": "file",
|
|
22
|
+
"required": true,
|
|
23
|
+
"hasDynamicHelp": false,
|
|
24
|
+
"multiple": true,
|
|
25
|
+
"type": "option"
|
|
26
|
+
}
|
|
27
|
+
},
|
|
28
|
+
"hasDynamicHelp": false,
|
|
29
|
+
"hiddenAliases": [],
|
|
30
|
+
"id": "apply",
|
|
31
|
+
"pluginAlias": "@flowcore/cli",
|
|
32
|
+
"pluginName": "@flowcore/cli",
|
|
33
|
+
"pluginType": "core",
|
|
34
|
+
"strict": true,
|
|
35
|
+
"enableJsonFlag": false,
|
|
36
|
+
"isESM": true,
|
|
37
|
+
"relativePath": [
|
|
38
|
+
"dist",
|
|
39
|
+
"commands",
|
|
40
|
+
"apply.js"
|
|
41
|
+
]
|
|
42
|
+
},
|
|
3
43
|
"stream": {
|
|
4
44
|
"aliases": [],
|
|
5
45
|
"args": {
|
|
@@ -101,5 +141,5 @@
|
|
|
101
141
|
]
|
|
102
142
|
}
|
|
103
143
|
},
|
|
104
|
-
"version": "2.
|
|
144
|
+
"version": "2.3.0"
|
|
105
145
|
}
|
package/package.json
CHANGED
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
"dependencies": {
|
|
7
7
|
"@datastructures-js/queue": "^4.2.3",
|
|
8
8
|
"@flowcore/cli-plugin-config": "^1.0.5",
|
|
9
|
-
"@flowcore/cli-plugin-data-core": "^1.
|
|
9
|
+
"@flowcore/cli-plugin-data-core": "^1.2.0",
|
|
10
10
|
"@flowcore/time-bucket": "^1.1.0",
|
|
11
11
|
"@oclif/core": "^3",
|
|
12
12
|
"@oclif/plugin-autocomplete": "^3.0.2",
|
|
@@ -87,7 +87,7 @@
|
|
|
87
87
|
"prestart": "npm run build",
|
|
88
88
|
"update-schema": "rover graph introspect https://graph.api.staging.flowcore.io/graphql -o schema.gql"
|
|
89
89
|
},
|
|
90
|
-
"version": "2.
|
|
90
|
+
"version": "2.3.0",
|
|
91
91
|
"bugs": "https://github.com/flowcore-io/flowcore-cli/issues",
|
|
92
92
|
"keywords": [
|
|
93
93
|
"flowcore",
|