@teambit/workspace 0.0.754 → 0.0.757
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/envs-subcommands/envs-unset.cmd.js +21 -3
- package/dist/envs-subcommands/envs-unset.cmd.js.map +1 -1
- package/envs-subcommands/envs-unset.cmd.ts +10 -3
- package/package-tar/teambit-workspace-0.0.757.tgz +0 -0
- package/package.json +32 -32
- package/{preview-1654658836872.js → preview-1654831618244.js} +2 -2
- package/package-tar/teambit-workspace-0.0.754.tgz +0 -0
|
@@ -31,14 +31,27 @@ function _constants() {
|
|
|
31
31
|
return data;
|
|
32
32
|
}
|
|
33
33
|
|
|
34
|
+
function _chalk() {
|
|
35
|
+
const data = _interopRequireDefault(require("chalk"));
|
|
36
|
+
|
|
37
|
+
_chalk = function () {
|
|
38
|
+
return data;
|
|
39
|
+
};
|
|
40
|
+
|
|
41
|
+
return data;
|
|
42
|
+
}
|
|
43
|
+
|
|
34
44
|
class EnvsUnsetCmd {
|
|
35
45
|
constructor(workspace) {
|
|
36
46
|
this.workspace = workspace;
|
|
37
|
-
(0, _defineProperty2().default)(this, "name", 'unset <
|
|
38
|
-
(0, _defineProperty2().default)(this, "description", 'unset an environment from component(s)');
|
|
47
|
+
(0, _defineProperty2().default)(this, "name", 'unset <pattern>');
|
|
48
|
+
(0, _defineProperty2().default)(this, "description", 'unset an environment from component(s) that was set by "bit env set"');
|
|
39
49
|
(0, _defineProperty2().default)(this, "options", []);
|
|
40
50
|
(0, _defineProperty2().default)(this, "group", 'development');
|
|
41
|
-
(0, _defineProperty2().default)(this, "extendedDescription",
|
|
51
|
+
(0, _defineProperty2().default)(this, "extendedDescription", `keep in mind that this doesn't remove envs that are set in the variants.
|
|
52
|
+
in only removes envs that appear in the .bitmap file, which were previously configured via "bit env set".
|
|
53
|
+
the purpose of this command is to remove the specific settings and let the the variants in workspace.jsonc to control the env.
|
|
54
|
+
${(0, _constants().PATTERN_HELP)('env unset')}`);
|
|
42
55
|
}
|
|
43
56
|
|
|
44
57
|
async report([pattern]) {
|
|
@@ -46,6 +59,11 @@ class EnvsUnsetCmd {
|
|
|
46
59
|
const {
|
|
47
60
|
changed
|
|
48
61
|
} = await this.workspace.unsetEnvFromComponents(componentIds);
|
|
62
|
+
|
|
63
|
+
if (!changed.length) {
|
|
64
|
+
return _chalk().default.yellow(`unable to find any component matching the pattern with env configured in the .bitmap file`);
|
|
65
|
+
}
|
|
66
|
+
|
|
49
67
|
return `successfully removed env from the following component(s):
|
|
50
68
|
${changed.map(id => id.toString()).join('\n')}`;
|
|
51
69
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["EnvsUnsetCmd","constructor","workspace","PATTERN_HELP","report","pattern","componentIds","idsByPattern","changed","unsetEnvFromComponents","map","id","toString","join"],"sources":["envs-unset.cmd.ts"],"sourcesContent":["import { Command } from '@teambit/cli';\nimport { PATTERN_HELP } from '@teambit/legacy/dist/constants';\nimport { Workspace } from '../workspace';\n\nexport class EnvsUnsetCmd implements Command {\n name = 'unset <
|
|
1
|
+
{"version":3,"names":["EnvsUnsetCmd","constructor","workspace","PATTERN_HELP","report","pattern","componentIds","idsByPattern","changed","unsetEnvFromComponents","length","chalk","yellow","map","id","toString","join"],"sources":["envs-unset.cmd.ts"],"sourcesContent":["import { Command } from '@teambit/cli';\nimport { PATTERN_HELP } from '@teambit/legacy/dist/constants';\nimport chalk from 'chalk';\nimport { Workspace } from '../workspace';\n\nexport class EnvsUnsetCmd implements Command {\n name = 'unset <pattern>';\n description = 'unset an environment from component(s) that was set by \"bit env set\"';\n options = [];\n group = 'development';\n extendedDescription = `keep in mind that this doesn't remove envs that are set in the variants.\nin only removes envs that appear in the .bitmap file, which were previously configured via \"bit env set\".\nthe purpose of this command is to remove the specific settings and let the the variants in workspace.jsonc to control the env.\n${PATTERN_HELP('env unset')}`;\n\n constructor(private workspace: Workspace) {}\n\n async report([pattern]: [string]) {\n const componentIds = await this.workspace.idsByPattern(pattern);\n const { changed } = await this.workspace.unsetEnvFromComponents(componentIds);\n if (!changed.length) {\n return chalk.yellow(`unable to find any component matching the pattern with env configured in the .bitmap file`);\n }\n return `successfully removed env from the following component(s):\n${changed.map((id) => id.toString()).join('\\n')}`;\n }\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AACA;EAAA;;EAAA;IAAA;EAAA;;EAAA;AAAA;;AACA;EAAA;;EAAA;IAAA;EAAA;;EAAA;AAAA;;AAGO,MAAMA,YAAN,CAAsC;EAU3CC,WAAW,CAASC,SAAT,EAA+B;IAAA,KAAtBA,SAAsB,GAAtBA,SAAsB;IAAA,8CATnC,iBASmC;IAAA,qDAR5B,sEAQ4B;IAAA,iDAPhC,EAOgC;IAAA,+CANlC,aAMkC;IAAA,6DALnB;AACzB;AACA;AACA,EAAE,IAAAC,yBAAA,EAAa,WAAb,CAA0B,EAEgB;EAAE;;EAEhC,MAANC,MAAM,CAAC,CAACC,OAAD,CAAD,EAAsB;IAChC,MAAMC,YAAY,GAAG,MAAM,KAAKJ,SAAL,CAAeK,YAAf,CAA4BF,OAA5B,CAA3B;IACA,MAAM;MAAEG;IAAF,IAAc,MAAM,KAAKN,SAAL,CAAeO,sBAAf,CAAsCH,YAAtC,CAA1B;;IACA,IAAI,CAACE,OAAO,CAACE,MAAb,EAAqB;MACnB,OAAOC,gBAAA,CAAMC,MAAN,CAAc,2FAAd,CAAP;IACD;;IACD,OAAQ;AACZ,EAAEJ,OAAO,CAACK,GAAR,CAAaC,EAAD,IAAQA,EAAE,CAACC,QAAH,EAApB,EAAmCC,IAAnC,CAAwC,IAAxC,CAA8C,EAD5C;EAED;;AApB0C"}
|
|
@@ -1,19 +1,26 @@
|
|
|
1
1
|
import { Command } from '@teambit/cli';
|
|
2
2
|
import { PATTERN_HELP } from '@teambit/legacy/dist/constants';
|
|
3
|
+
import chalk from 'chalk';
|
|
3
4
|
import { Workspace } from '../workspace';
|
|
4
5
|
|
|
5
6
|
export class EnvsUnsetCmd implements Command {
|
|
6
|
-
name = 'unset <
|
|
7
|
-
description = 'unset an environment from component(s)';
|
|
7
|
+
name = 'unset <pattern>';
|
|
8
|
+
description = 'unset an environment from component(s) that was set by "bit env set"';
|
|
8
9
|
options = [];
|
|
9
10
|
group = 'development';
|
|
10
|
-
extendedDescription =
|
|
11
|
+
extendedDescription = `keep in mind that this doesn't remove envs that are set in the variants.
|
|
12
|
+
in only removes envs that appear in the .bitmap file, which were previously configured via "bit env set".
|
|
13
|
+
the purpose of this command is to remove the specific settings and let the the variants in workspace.jsonc to control the env.
|
|
14
|
+
${PATTERN_HELP('env unset')}`;
|
|
11
15
|
|
|
12
16
|
constructor(private workspace: Workspace) {}
|
|
13
17
|
|
|
14
18
|
async report([pattern]: [string]) {
|
|
15
19
|
const componentIds = await this.workspace.idsByPattern(pattern);
|
|
16
20
|
const { changed } = await this.workspace.unsetEnvFromComponents(componentIds);
|
|
21
|
+
if (!changed.length) {
|
|
22
|
+
return chalk.yellow(`unable to find any component matching the pattern with env configured in the .bitmap file`);
|
|
23
|
+
}
|
|
17
24
|
return `successfully removed env from the following component(s):
|
|
18
25
|
${changed.map((id) => id.toString()).join('\n')}`;
|
|
19
26
|
}
|
|
Binary file
|
package/package.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@teambit/workspace",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.757",
|
|
4
4
|
"homepage": "https://bit.dev/teambit/workspace/workspace",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"componentId": {
|
|
7
7
|
"scope": "teambit.workspace",
|
|
8
8
|
"name": "workspace",
|
|
9
|
-
"version": "0.0.
|
|
9
|
+
"version": "0.0.757"
|
|
10
10
|
},
|
|
11
11
|
"dependencies": {
|
|
12
12
|
"lodash": "4.17.21",
|
|
@@ -39,46 +39,46 @@
|
|
|
39
39
|
"@teambit/bit-error": "0.0.394",
|
|
40
40
|
"@teambit/component-id": "0.0.402",
|
|
41
41
|
"@teambit/legacy-bit-id": "0.0.399",
|
|
42
|
-
"@teambit/logger": "0.0.
|
|
43
|
-
"@teambit/scope": "0.0.
|
|
44
|
-
"@teambit/cli": "0.0.
|
|
45
|
-
"@teambit/isolator": "0.0.
|
|
46
|
-
"@teambit/component-tree": "0.0.
|
|
42
|
+
"@teambit/logger": "0.0.593",
|
|
43
|
+
"@teambit/scope": "0.0.757",
|
|
44
|
+
"@teambit/cli": "0.0.500",
|
|
45
|
+
"@teambit/isolator": "0.0.757",
|
|
46
|
+
"@teambit/component-tree": "0.0.545",
|
|
47
47
|
"@teambit/component.ui.component-status-resolver": "0.0.492",
|
|
48
|
-
"@teambit/lanes.ui.lanes": "0.0.
|
|
48
|
+
"@teambit/lanes.ui.lanes": "0.0.67",
|
|
49
49
|
"@teambit/harmony.modules.resolved-component": "0.0.484",
|
|
50
|
-
"@teambit/dependency-resolver": "0.0.
|
|
51
|
-
"@teambit/compiler": "0.0.
|
|
52
|
-
"@teambit/component": "0.0.
|
|
53
|
-
"@teambit/graphql": "0.0.
|
|
54
|
-
"@teambit/aspect-loader": "0.0.
|
|
55
|
-
"@teambit/bundler": "0.0.
|
|
56
|
-
"@teambit/community": "0.0.
|
|
57
|
-
"@teambit/envs": "0.0.
|
|
58
|
-
"@teambit/pubsub": "0.0.
|
|
59
|
-
"@teambit/ui": "0.0.
|
|
60
|
-
"@teambit/variants": "0.0.
|
|
61
|
-
"@teambit/component-issues": "0.0.
|
|
62
|
-
"@teambit/config": "0.0.
|
|
50
|
+
"@teambit/dependency-resolver": "0.0.757",
|
|
51
|
+
"@teambit/compiler": "0.0.757",
|
|
52
|
+
"@teambit/component": "0.0.757",
|
|
53
|
+
"@teambit/graphql": "0.0.757",
|
|
54
|
+
"@teambit/aspect-loader": "0.0.757",
|
|
55
|
+
"@teambit/bundler": "0.0.757",
|
|
56
|
+
"@teambit/community": "0.0.48",
|
|
57
|
+
"@teambit/envs": "0.0.757",
|
|
58
|
+
"@teambit/pubsub": "0.0.757",
|
|
59
|
+
"@teambit/ui": "0.0.757",
|
|
60
|
+
"@teambit/variants": "0.0.596",
|
|
61
|
+
"@teambit/component-issues": "0.0.54",
|
|
62
|
+
"@teambit/config": "0.0.513",
|
|
63
63
|
"@teambit/harmony.modules.requireable-component": "0.0.484",
|
|
64
|
-
"@teambit/importer": "0.0.
|
|
65
|
-
"@teambit/lane-id": "0.0.
|
|
64
|
+
"@teambit/importer": "0.0.186",
|
|
65
|
+
"@teambit/lane-id": "0.0.19",
|
|
66
66
|
"@teambit/workspace.modules.match-pattern": "0.0.489",
|
|
67
|
-
"@teambit/component.ui.component-drawer": "0.0.
|
|
67
|
+
"@teambit/component.ui.component-drawer": "0.0.46",
|
|
68
68
|
"@teambit/design.ui.tree": "0.0.5",
|
|
69
|
-
"@teambit/ui-foundation.ui.side-bar": "0.0.
|
|
70
|
-
"@teambit/command-bar": "0.0.
|
|
69
|
+
"@teambit/ui-foundation.ui.side-bar": "0.0.564",
|
|
70
|
+
"@teambit/command-bar": "0.0.757",
|
|
71
71
|
"@teambit/component.ui.component-filters": "0.0.5",
|
|
72
|
-
"@teambit/graph": "0.0.
|
|
73
|
-
"@teambit/sidebar": "0.0.
|
|
72
|
+
"@teambit/graph": "0.0.757",
|
|
73
|
+
"@teambit/sidebar": "0.0.757",
|
|
74
74
|
"@teambit/ui-foundation.ui.main-dropdown": "0.0.487",
|
|
75
75
|
"@teambit/ui-foundation.ui.menu": "0.0.487",
|
|
76
76
|
"@teambit/ui-foundation.ui.react-router.slot-router": "0.0.490",
|
|
77
77
|
"@teambit/ui-foundation.ui.tree.drawer": "0.0.499",
|
|
78
78
|
"@teambit/toolbox.time.time-format": "0.0.483",
|
|
79
79
|
"@teambit/ui-foundation.ui.hooks.use-data-query": "0.0.487",
|
|
80
|
-
"@teambit/component-descriptor": "0.0.
|
|
81
|
-
"@teambit/deprecation": "0.0.
|
|
80
|
+
"@teambit/component-descriptor": "0.0.62",
|
|
81
|
+
"@teambit/deprecation": "0.0.757",
|
|
82
82
|
"@teambit/ui-foundation.ui.constants.z-indexes": "0.0.487",
|
|
83
83
|
"@teambit/ui-foundation.ui.buttons.collapser": "0.0.194",
|
|
84
84
|
"@teambit/ui-foundation.ui.corner": "0.0.498",
|
|
@@ -105,7 +105,7 @@
|
|
|
105
105
|
"peerDependencies": {
|
|
106
106
|
"react-router-dom": "^6.0.0",
|
|
107
107
|
"@apollo/client": "^3.0.0",
|
|
108
|
-
"@teambit/legacy": "1.0.
|
|
108
|
+
"@teambit/legacy": "1.0.280",
|
|
109
109
|
"react-dom": "^16.8.0 || ^17.0.0",
|
|
110
110
|
"react": "^16.8.0 || ^17.0.0"
|
|
111
111
|
},
|
|
@@ -133,7 +133,7 @@
|
|
|
133
133
|
"react": "-"
|
|
134
134
|
},
|
|
135
135
|
"peerDependencies": {
|
|
136
|
-
"@teambit/legacy": "1.0.
|
|
136
|
+
"@teambit/legacy": "1.0.280",
|
|
137
137
|
"react-dom": "^16.8.0 || ^17.0.0",
|
|
138
138
|
"react": "^16.8.0 || ^17.0.0"
|
|
139
139
|
}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export const compositions = [require('/home/circleci/Library/Caches/Bit/capsules/8891be5ad3d35bfc38b9cd90c0e05b598a5a55af/teambit.workspace_workspace@0.0.
|
|
2
|
-
export const overview = [require('/home/circleci/Library/Caches/Bit/capsules/8891be5ad3d35bfc38b9cd90c0e05b598a5a55af/teambit.workspace_workspace@0.0.
|
|
1
|
+
export const compositions = [require('/home/circleci/Library/Caches/Bit/capsules/8891be5ad3d35bfc38b9cd90c0e05b598a5a55af/teambit.workspace_workspace@0.0.757/dist/workspace.composition.js')]
|
|
2
|
+
export const overview = [require('/home/circleci/Library/Caches/Bit/capsules/8891be5ad3d35bfc38b9cd90c0e05b598a5a55af/teambit.workspace_workspace@0.0.757/dist/workspace.docs.mdx')]
|
|
Binary file
|