@teambit/component-compare 1.0.2 → 1.0.4
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.
|
@@ -2,6 +2,7 @@ import { CLIMain } from '@teambit/cli';
|
|
|
2
2
|
import { Workspace } from '@teambit/workspace';
|
|
3
3
|
import { ScopeMain } from '@teambit/scope';
|
|
4
4
|
import { GraphqlMain } from '@teambit/graphql';
|
|
5
|
+
import { DependencyResolverMain } from '@teambit/dependency-resolver';
|
|
5
6
|
import { LoggerMain, Logger } from '@teambit/logger';
|
|
6
7
|
import { FieldsDiff, FileDiff } from '@teambit/legacy/dist/consumer/component-ops/components-diff';
|
|
7
8
|
import { TesterMain } from '@teambit/tester';
|
|
@@ -12,28 +13,36 @@ export declare type ComponentCompareResult = {
|
|
|
12
13
|
fields: FieldsDiff[];
|
|
13
14
|
tests: FileDiff[];
|
|
14
15
|
};
|
|
16
|
+
declare type ConfigDiff = {
|
|
17
|
+
version?: string;
|
|
18
|
+
dependencies?: string[];
|
|
19
|
+
aspects?: Record<string, any>;
|
|
20
|
+
};
|
|
15
21
|
export declare class ComponentCompareMain {
|
|
16
22
|
private componentAspect;
|
|
17
23
|
private scope;
|
|
18
24
|
private logger;
|
|
19
25
|
private tester;
|
|
26
|
+
private depResolver;
|
|
20
27
|
private workspace?;
|
|
21
|
-
constructor(componentAspect: ComponentMain, scope: ScopeMain, logger: Logger, tester: TesterMain, workspace?: Workspace | undefined);
|
|
28
|
+
constructor(componentAspect: ComponentMain, scope: ScopeMain, logger: Logger, tester: TesterMain, depResolver: DependencyResolverMain, workspace?: Workspace | undefined);
|
|
22
29
|
compare(baseIdStr: string, compareIdStr: string): Promise<ComponentCompareResult>;
|
|
23
30
|
diffByCLIValues(values: string[], verbose: boolean, table: boolean): Promise<any>;
|
|
31
|
+
getConfigForDiff(id: string): Promise<ConfigDiff>;
|
|
24
32
|
private parseValues;
|
|
25
33
|
private getBitIdsForDiff;
|
|
26
34
|
static slots: never[];
|
|
27
35
|
static dependencies: import("@teambit/harmony").Aspect[];
|
|
28
36
|
static runtime: import("@teambit/harmony").RuntimeDefinition;
|
|
29
|
-
static provider([graphql, component, scope, loggerMain, cli, workspace, tester]: [
|
|
37
|
+
static provider([graphql, component, scope, loggerMain, cli, workspace, tester, depResolver]: [
|
|
30
38
|
GraphqlMain,
|
|
31
39
|
ComponentMain,
|
|
32
40
|
ScopeMain,
|
|
33
41
|
LoggerMain,
|
|
34
42
|
CLIMain,
|
|
35
43
|
Workspace,
|
|
36
|
-
TesterMain
|
|
44
|
+
TesterMain,
|
|
45
|
+
DependencyResolverMain
|
|
37
46
|
]): Promise<ComponentCompareMain>;
|
|
38
47
|
}
|
|
39
48
|
export default ComponentCompareMain;
|
|
@@ -60,6 +60,13 @@ function _graphql() {
|
|
|
60
60
|
};
|
|
61
61
|
return data;
|
|
62
62
|
}
|
|
63
|
+
function _builder() {
|
|
64
|
+
const data = _interopRequireDefault(require("@teambit/builder"));
|
|
65
|
+
_builder = function () {
|
|
66
|
+
return data;
|
|
67
|
+
};
|
|
68
|
+
return data;
|
|
69
|
+
}
|
|
63
70
|
function _generalError() {
|
|
64
71
|
const data = _interopRequireDefault(require("@teambit/legacy/dist/error/general-error"));
|
|
65
72
|
_generalError = function () {
|
|
@@ -67,6 +74,13 @@ function _generalError() {
|
|
|
67
74
|
};
|
|
68
75
|
return data;
|
|
69
76
|
}
|
|
77
|
+
function _dependencyResolver() {
|
|
78
|
+
const data = _interopRequireDefault(require("@teambit/dependency-resolver"));
|
|
79
|
+
_dependencyResolver = function () {
|
|
80
|
+
return data;
|
|
81
|
+
};
|
|
82
|
+
return data;
|
|
83
|
+
}
|
|
70
84
|
function _logger() {
|
|
71
85
|
const data = require("@teambit/logger");
|
|
72
86
|
_logger = function () {
|
|
@@ -123,11 +137,12 @@ function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key i
|
|
|
123
137
|
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return typeof key === "symbol" ? key : String(key); }
|
|
124
138
|
function _toPrimitive(input, hint) { if (typeof input !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (typeof res !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
125
139
|
class ComponentCompareMain {
|
|
126
|
-
constructor(componentAspect, scope, logger, tester, workspace) {
|
|
140
|
+
constructor(componentAspect, scope, logger, tester, depResolver, workspace) {
|
|
127
141
|
this.componentAspect = componentAspect;
|
|
128
142
|
this.scope = scope;
|
|
129
143
|
this.logger = logger;
|
|
130
144
|
this.tester = tester;
|
|
145
|
+
this.depResolver = depResolver;
|
|
131
146
|
this.workspace = workspace;
|
|
132
147
|
}
|
|
133
148
|
async compare(baseIdStr, compareIdStr) {
|
|
@@ -175,6 +190,31 @@ class ComponentCompareMain {
|
|
|
175
190
|
await consumer.onDestroy();
|
|
176
191
|
return diffResults;
|
|
177
192
|
}
|
|
193
|
+
async getConfigForDiff(id) {
|
|
194
|
+
const workspace = this.workspace;
|
|
195
|
+
if (!workspace) throw new (_workspace().OutsideWorkspaceError)();
|
|
196
|
+
const componentId = await workspace.resolveComponentId(id);
|
|
197
|
+
const component = await workspace.scope.get(componentId);
|
|
198
|
+
if (!component) throw new Error(`getConfigForDiff: unable to find component ${id} in local scope`);
|
|
199
|
+
const depData = await this.depResolver.getDependencies(component);
|
|
200
|
+
const serializedToString = dep => {
|
|
201
|
+
const idWithoutVersion = dep.__type === 'package' ? dep.id : dep.id.split('@')[0];
|
|
202
|
+
return `${idWithoutVersion}@${dep.version} (${dep.lifecycle}) ${dep.source ? `(${dep.source})` : ''}`;
|
|
203
|
+
};
|
|
204
|
+
const serializeAndSort = deps => {
|
|
205
|
+
const serialized = deps.serialize().map(serializedToString);
|
|
206
|
+
return serialized.sort();
|
|
207
|
+
};
|
|
208
|
+
const serializeAspect = comp => {
|
|
209
|
+
const aspects = comp.state.aspects.withoutEntries([_builder().default.id, _dependencyResolver().default.id]);
|
|
210
|
+
return aspects.serialize();
|
|
211
|
+
};
|
|
212
|
+
return {
|
|
213
|
+
version: componentId.version,
|
|
214
|
+
dependencies: serializeAndSort(depData),
|
|
215
|
+
aspects: serializeAspect(component)
|
|
216
|
+
};
|
|
217
|
+
}
|
|
178
218
|
async parseValues(values) {
|
|
179
219
|
if (!this.workspace) throw new (_workspace().OutsideWorkspaceError)();
|
|
180
220
|
const consumer = this.workspace.consumer;
|
|
@@ -231,9 +271,9 @@ class ComponentCompareMain {
|
|
|
231
271
|
}
|
|
232
272
|
return ids.map(id => consumer.getParsedId(id));
|
|
233
273
|
}
|
|
234
|
-
static async provider([graphql, component, scope, loggerMain, cli, workspace, tester]) {
|
|
274
|
+
static async provider([graphql, component, scope, loggerMain, cli, workspace, tester, depResolver]) {
|
|
235
275
|
const logger = loggerMain.createLogger(_componentCompare2().ComponentCompareAspect.id);
|
|
236
|
-
const componentCompareMain = new ComponentCompareMain(component, scope, logger, tester, workspace);
|
|
276
|
+
const componentCompareMain = new ComponentCompareMain(component, scope, logger, tester, depResolver, workspace);
|
|
237
277
|
cli.register(new (_diffCmd().DiffCmd)(componentCompareMain));
|
|
238
278
|
graphql.register((0, _componentCompare().componentCompareSchema)(componentCompareMain));
|
|
239
279
|
return componentCompareMain;
|
|
@@ -241,7 +281,7 @@ class ComponentCompareMain {
|
|
|
241
281
|
}
|
|
242
282
|
exports.ComponentCompareMain = ComponentCompareMain;
|
|
243
283
|
_defineProperty(ComponentCompareMain, "slots", []);
|
|
244
|
-
_defineProperty(ComponentCompareMain, "dependencies", [_graphql().GraphqlAspect, _component().default, _scope().ScopeAspect, _logger().LoggerAspect, _cli().CLIAspect, _workspace().WorkspaceAspect, _tester().TesterAspect]);
|
|
284
|
+
_defineProperty(ComponentCompareMain, "dependencies", [_graphql().GraphqlAspect, _component().default, _scope().ScopeAspect, _logger().LoggerAspect, _cli().CLIAspect, _workspace().WorkspaceAspect, _tester().TesterAspect, _dependencyResolver().default]);
|
|
245
285
|
_defineProperty(ComponentCompareMain, "runtime", _cli().MainRuntime);
|
|
246
286
|
_componentCompare2().ComponentCompareAspect.addRuntime(ComponentCompareMain);
|
|
247
287
|
var _default = ComponentCompareMain;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_cli","data","require","_bitError","_workspace","_legacyBitId","_componentsList","_interopRequireDefault","_hasWildcard","_scope","_graphql","_generalError","_logger","_componentsDiff","_interopRequireWildcard","_tester","_component","_componentCompare","_componentCompare2","_diffCmd","_getRequireWildcardCache","nodeInterop","WeakMap","cacheBabelInterop","cacheNodeInterop","obj","__esModule","default","cache","has","get","newObj","hasPropertyDescriptor","Object","defineProperty","getOwnPropertyDescriptor","key","prototype","hasOwnProperty","call","desc","set","_defineProperty","value","_toPropertyKey","enumerable","configurable","writable","arg","_toPrimitive","String","input","hint","prim","Symbol","toPrimitive","undefined","res","TypeError","Number","ComponentCompareMain","constructor","componentAspect","scope","logger","tester","workspace","compare","baseIdStr","compareIdStr","host","getHost","baseCompId","compareCompId","resolveMultipleComponentIds","modelComponent","legacyScope","getModelComponentIfExist","_legacy","GeneralError","toString","baseVersion","version","compareVersion","repository","objects","baseVersionObject","loadVersion","compareVersionObject","diff","diffBetweenVersionsObjects","baseComponent","compareComponent","baseTestFiles","getTestFiles","map","file","relative","compareTestFiles","allTestFiles","testFilesDiff","filesDiff","filter","fileDiff","includes","filePath","status","compareResult","id","code","fields","fieldsDiff","tests","diffByCLIValues","values","verbose","table","OutsideWorkspaceError","consumer","bitIds","toVersion","parseValues","length","BitError","diffResults","componentsDiff","formatDepsAsTable","onDestroy","componentsList","ComponentsList","listTagPendingComponents","firstValue","lastValue","oneBeforeLastValue","isLastItemVersion","BitId","isValidVersion","isOneBeforeLastItemVersion","getBitIdsForDiff","ids","hasWildcard","listComponentsByIdsWithWildcard","getParsedId","provider","graphql","component","loggerMain","cli","createLogger","ComponentCompareAspect","componentCompareMain","register","DiffCmd","componentCompareSchema","exports","GraphqlAspect","ComponentAspect","ScopeAspect","LoggerAspect","CLIAspect","WorkspaceAspect","TesterAspect","MainRuntime","addRuntime","_default"],"sources":["component-compare.main.runtime.ts"],"sourcesContent":["import { CLIAspect, CLIMain, MainRuntime } from '@teambit/cli';\nimport { BitError } from '@teambit/bit-error';\nimport { WorkspaceAspect, OutsideWorkspaceError, Workspace } from '@teambit/workspace';\nimport { BitId } from '@teambit/legacy-bit-id';\nimport ComponentsList from '@teambit/legacy/dist/consumer/component/components-list';\nimport hasWildcard from '@teambit/legacy/dist/utils/string/has-wildcard';\nimport { ScopeMain, ScopeAspect } from '@teambit/scope';\nimport { GraphqlAspect, GraphqlMain } from '@teambit/graphql';\nimport GeneralError from '@teambit/legacy/dist/error/general-error';\nimport { LoggerAspect, LoggerMain, Logger } from '@teambit/logger';\nimport componentsDiff, {\n diffBetweenVersionsObjects,\n DiffResults,\n FieldsDiff,\n FileDiff,\n} from '@teambit/legacy/dist/consumer/component-ops/components-diff';\nimport { TesterMain, TesterAspect } from '@teambit/tester';\nimport ComponentAspect, { ComponentMain } from '@teambit/component';\nimport { componentCompareSchema } from './component-compare.graphql';\nimport { ComponentCompareAspect } from './component-compare.aspect';\nimport { DiffCmd } from './diff-cmd';\n\nexport type ComponentCompareResult = {\n id: string;\n code: FileDiff[];\n fields: FieldsDiff[];\n tests: FileDiff[];\n};\n\nexport class ComponentCompareMain {\n constructor(\n private componentAspect: ComponentMain,\n private scope: ScopeMain,\n private logger: Logger,\n private tester: TesterMain,\n private workspace?: Workspace\n ) {}\n\n async compare(baseIdStr: string, compareIdStr: string): Promise<ComponentCompareResult> {\n const host = this.componentAspect.getHost();\n const [baseCompId, compareCompId] = await host.resolveMultipleComponentIds([baseIdStr, compareIdStr]);\n const modelComponent = await this.scope.legacyScope.getModelComponentIfExist(compareCompId._legacy);\n\n if (!modelComponent) {\n throw new GeneralError(`component ${compareCompId.toString()} doesn't have any version yet`);\n }\n\n const baseVersion = baseCompId.version as string;\n const compareVersion = compareCompId.version as string;\n\n const repository = this.scope.legacyScope.objects;\n const baseVersionObject = await modelComponent.loadVersion(baseVersion, repository);\n const compareVersionObject = await modelComponent.loadVersion(compareVersion, repository);\n\n const diff: DiffResults = await diffBetweenVersionsObjects(\n modelComponent,\n baseVersionObject,\n compareVersionObject,\n baseVersion,\n compareVersion,\n this.scope.legacyScope,\n {}\n );\n\n const baseComponent = await host.get(baseCompId);\n const compareComponent = await host.get(compareCompId);\n\n const baseTestFiles =\n (baseComponent && (await this.tester.getTestFiles(baseComponent).map((file) => file.relative))) || [];\n const compareTestFiles =\n (compareComponent && (await this.tester.getTestFiles(compareComponent).map((file) => file.relative))) || [];\n\n const allTestFiles = [...baseTestFiles, ...compareTestFiles];\n\n const testFilesDiff = (diff.filesDiff || []).filter(\n (fileDiff: FileDiff) => allTestFiles.includes(fileDiff.filePath) && fileDiff.status !== 'UNCHANGED'\n );\n\n const compareResult = {\n id: `${baseCompId}-${compareCompId}`,\n code: diff.filesDiff || [],\n fields: diff.fieldsDiff || [],\n tests: testFilesDiff,\n };\n\n return compareResult;\n }\n\n async diffByCLIValues(values: string[], verbose: boolean, table: boolean): Promise<any> {\n if (!this.workspace) throw new OutsideWorkspaceError();\n const consumer = this.workspace.consumer;\n const { bitIds, version, toVersion } = await this.parseValues(values);\n if (!bitIds || !bitIds.length) {\n throw new BitError('there are no modified components to diff');\n }\n const diffResults = await componentsDiff(consumer, bitIds, version, toVersion, {\n verbose,\n formatDepsAsTable: table,\n });\n await consumer.onDestroy();\n return diffResults;\n }\n\n private async parseValues(values: string[]): Promise<{ bitIds: BitId[]; version?: string; toVersion?: string }> {\n if (!this.workspace) throw new OutsideWorkspaceError();\n const consumer = this.workspace.consumer;\n // option #1: bit diff\n // no arguments\n if (!values.length) {\n const componentsList = new ComponentsList(consumer);\n const bitIds = await componentsList.listTagPendingComponents();\n // @ts-ignore AUTO-ADDED-AFTER-MIGRATION-PLEASE-FIX!\n return { bitIds };\n }\n const firstValue = values[0];\n const lastValue = values[values.length - 1];\n const oneBeforeLastValue = values[values.length - 2];\n const isLastItemVersion = BitId.isValidVersion(lastValue);\n const isOneBeforeLastItemVersion = BitId.isValidVersion(oneBeforeLastValue);\n // option #2: bit diff [ids...]\n // all arguments are ids\n if (!isLastItemVersion) {\n return { bitIds: this.getBitIdsForDiff(values) };\n }\n // option #3: bit diff [id] [version]\n // last argument is a version, first argument is id\n if (!isOneBeforeLastItemVersion) {\n if (values.length !== 2) {\n throw new BitError(\n `bit diff [id] [version] syntax was used, however, ${values.length} arguments were given instead of 2`\n );\n }\n return { bitIds: this.getBitIdsForDiff([firstValue]), version: lastValue };\n }\n // option #4: bit diff [id] [version] [to_version]\n // last argument and one before the last are versions, first argument is id\n if (values.length !== 3) {\n throw new BitError(\n `bit diff [id] [version] [to_version] syntax was used, however, ${values.length} arguments were given instead of 3`\n );\n }\n return { bitIds: this.getBitIdsForDiff([firstValue]), version: oneBeforeLastValue, toVersion: lastValue };\n }\n\n private getBitIdsForDiff(ids: string[]): BitId[] {\n if (!this.workspace) throw new OutsideWorkspaceError();\n const consumer = this.workspace.consumer;\n if (hasWildcard(ids)) {\n const componentsList = new ComponentsList(consumer);\n return componentsList.listComponentsByIdsWithWildcard(ids);\n }\n return ids.map((id) => consumer.getParsedId(id));\n }\n\n static slots = [];\n static dependencies = [\n GraphqlAspect,\n ComponentAspect,\n ScopeAspect,\n LoggerAspect,\n CLIAspect,\n WorkspaceAspect,\n TesterAspect,\n ];\n static runtime = MainRuntime;\n static async provider([graphql, component, scope, loggerMain, cli, workspace, tester]: [\n GraphqlMain,\n ComponentMain,\n ScopeMain,\n LoggerMain,\n CLIMain,\n Workspace,\n TesterMain\n ]) {\n const logger = loggerMain.createLogger(ComponentCompareAspect.id);\n const componentCompareMain = new ComponentCompareMain(component, scope, logger, tester, workspace);\n cli.register(new DiffCmd(componentCompareMain));\n graphql.register(componentCompareSchema(componentCompareMain));\n return componentCompareMain;\n }\n}\n\nComponentCompareAspect.addRu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B,CAAC;AAAC,IAAAwG,QAAA,GAEzCxG,oBAAoB;AAAA8F,OAAA,CAAA/H,OAAA,GAAAyI,QAAA"}
|
|
1
|
+
{"version":3,"names":["_cli","data","require","_bitError","_workspace","_legacyBitId","_componentsList","_interopRequireDefault","_hasWildcard","_scope","_graphql","_builder","_generalError","_dependencyResolver","_logger","_componentsDiff","_interopRequireWildcard","_tester","_component","_componentCompare","_componentCompare2","_diffCmd","_getRequireWildcardCache","nodeInterop","WeakMap","cacheBabelInterop","cacheNodeInterop","obj","__esModule","default","cache","has","get","newObj","hasPropertyDescriptor","Object","defineProperty","getOwnPropertyDescriptor","key","prototype","hasOwnProperty","call","desc","set","_defineProperty","value","_toPropertyKey","enumerable","configurable","writable","arg","_toPrimitive","String","input","hint","prim","Symbol","toPrimitive","undefined","res","TypeError","Number","ComponentCompareMain","constructor","componentAspect","scope","logger","tester","depResolver","workspace","compare","baseIdStr","compareIdStr","host","getHost","baseCompId","compareCompId","resolveMultipleComponentIds","modelComponent","legacyScope","getModelComponentIfExist","_legacy","GeneralError","toString","baseVersion","version","compareVersion","repository","objects","baseVersionObject","loadVersion","compareVersionObject","diff","diffBetweenVersionsObjects","baseComponent","compareComponent","baseTestFiles","getTestFiles","map","file","relative","compareTestFiles","allTestFiles","testFilesDiff","filesDiff","filter","fileDiff","includes","filePath","status","compareResult","id","code","fields","fieldsDiff","tests","diffByCLIValues","values","verbose","table","OutsideWorkspaceError","consumer","bitIds","toVersion","parseValues","length","BitError","diffResults","componentsDiff","formatDepsAsTable","onDestroy","getConfigForDiff","componentId","resolveComponentId","component","Error","depData","getDependencies","serializedToString","dep","idWithoutVersion","__type","split","lifecycle","source","serializeAndSort","deps","serialized","serialize","sort","serializeAspect","comp","aspects","state","withoutEntries","BuilderAspect","DependencyResolverAspect","dependencies","componentsList","ComponentsList","listTagPendingComponents","firstValue","lastValue","oneBeforeLastValue","isLastItemVersion","BitId","isValidVersion","isOneBeforeLastItemVersion","getBitIdsForDiff","ids","hasWildcard","listComponentsByIdsWithWildcard","getParsedId","provider","graphql","loggerMain","cli","createLogger","ComponentCompareAspect","componentCompareMain","register","DiffCmd","componentCompareSchema","exports","GraphqlAspect","ComponentAspect","ScopeAspect","LoggerAspect","CLIAspect","WorkspaceAspect","TesterAspect","MainRuntime","addRuntime","_default"],"sources":["component-compare.main.runtime.ts"],"sourcesContent":["import { CLIAspect, CLIMain, MainRuntime } from '@teambit/cli';\nimport { BitError } from '@teambit/bit-error';\nimport { WorkspaceAspect, OutsideWorkspaceError, Workspace } from '@teambit/workspace';\nimport { BitId } from '@teambit/legacy-bit-id';\nimport ComponentsList from '@teambit/legacy/dist/consumer/component/components-list';\nimport hasWildcard from '@teambit/legacy/dist/utils/string/has-wildcard';\nimport { ScopeMain, ScopeAspect } from '@teambit/scope';\nimport { GraphqlAspect, GraphqlMain } from '@teambit/graphql';\nimport BuilderAspect from '@teambit/builder';\nimport GeneralError from '@teambit/legacy/dist/error/general-error';\nimport DependencyResolverAspect, {\n DependencyList,\n DependencyResolverMain,\n SerializedDependency,\n} from '@teambit/dependency-resolver';\nimport { LoggerAspect, LoggerMain, Logger } from '@teambit/logger';\nimport componentsDiff, {\n diffBetweenVersionsObjects,\n DiffResults,\n FieldsDiff,\n FileDiff,\n} from '@teambit/legacy/dist/consumer/component-ops/components-diff';\nimport { TesterMain, TesterAspect } from '@teambit/tester';\nimport ComponentAspect, { Component, ComponentMain } from '@teambit/component';\nimport { componentCompareSchema } from './component-compare.graphql';\nimport { ComponentCompareAspect } from './component-compare.aspect';\nimport { DiffCmd } from './diff-cmd';\n\nexport type ComponentCompareResult = {\n id: string;\n code: FileDiff[];\n fields: FieldsDiff[];\n tests: FileDiff[];\n};\n\ntype ConfigDiff = {\n version?: string;\n dependencies?: string[];\n aspects?: Record<string, any>;\n};\n\nexport class ComponentCompareMain {\n constructor(\n private componentAspect: ComponentMain,\n private scope: ScopeMain,\n private logger: Logger,\n private tester: TesterMain,\n private depResolver: DependencyResolverMain,\n private workspace?: Workspace\n ) {}\n\n async compare(baseIdStr: string, compareIdStr: string): Promise<ComponentCompareResult> {\n const host = this.componentAspect.getHost();\n const [baseCompId, compareCompId] = await host.resolveMultipleComponentIds([baseIdStr, compareIdStr]);\n const modelComponent = await this.scope.legacyScope.getModelComponentIfExist(compareCompId._legacy);\n\n if (!modelComponent) {\n throw new GeneralError(`component ${compareCompId.toString()} doesn't have any version yet`);\n }\n\n const baseVersion = baseCompId.version as string;\n const compareVersion = compareCompId.version as string;\n\n const repository = this.scope.legacyScope.objects;\n const baseVersionObject = await modelComponent.loadVersion(baseVersion, repository);\n const compareVersionObject = await modelComponent.loadVersion(compareVersion, repository);\n\n const diff: DiffResults = await diffBetweenVersionsObjects(\n modelComponent,\n baseVersionObject,\n compareVersionObject,\n baseVersion,\n compareVersion,\n this.scope.legacyScope,\n {}\n );\n\n const baseComponent = await host.get(baseCompId);\n const compareComponent = await host.get(compareCompId);\n\n const baseTestFiles =\n (baseComponent && (await this.tester.getTestFiles(baseComponent).map((file) => file.relative))) || [];\n const compareTestFiles =\n (compareComponent && (await this.tester.getTestFiles(compareComponent).map((file) => file.relative))) || [];\n\n const allTestFiles = [...baseTestFiles, ...compareTestFiles];\n\n const testFilesDiff = (diff.filesDiff || []).filter(\n (fileDiff: FileDiff) => allTestFiles.includes(fileDiff.filePath) && fileDiff.status !== 'UNCHANGED'\n );\n\n const compareResult = {\n id: `${baseCompId}-${compareCompId}`,\n code: diff.filesDiff || [],\n fields: diff.fieldsDiff || [],\n tests: testFilesDiff,\n };\n\n return compareResult;\n }\n\n async diffByCLIValues(values: string[], verbose: boolean, table: boolean): Promise<any> {\n if (!this.workspace) throw new OutsideWorkspaceError();\n const consumer = this.workspace.consumer;\n const { bitIds, version, toVersion } = await this.parseValues(values);\n if (!bitIds || !bitIds.length) {\n throw new BitError('there are no modified components to diff');\n }\n const diffResults = await componentsDiff(consumer, bitIds, version, toVersion, {\n verbose,\n formatDepsAsTable: table,\n });\n await consumer.onDestroy();\n return diffResults;\n }\n\n async getConfigForDiff(id: string): Promise<ConfigDiff> {\n const workspace = this.workspace;\n if (!workspace) throw new OutsideWorkspaceError();\n const componentId = await workspace.resolveComponentId(id);\n const component = await workspace.scope.get(componentId);\n if (!component) throw new Error(`getConfigForDiff: unable to find component ${id} in local scope`);\n const depData = await this.depResolver.getDependencies(component);\n const serializedToString = (dep: SerializedDependency) => {\n const idWithoutVersion = dep.__type === 'package' ? dep.id : dep.id.split('@')[0];\n return `${idWithoutVersion}@${dep.version} (${dep.lifecycle}) ${dep.source ? `(${dep.source})` : ''}`;\n };\n const serializeAndSort = (deps: DependencyList) => {\n const serialized = deps.serialize().map(serializedToString);\n return serialized.sort();\n };\n const serializeAspect = (comp: Component) => {\n const aspects = comp.state.aspects.withoutEntries([BuilderAspect.id, DependencyResolverAspect.id]);\n return aspects.serialize();\n };\n return {\n version: componentId.version,\n dependencies: serializeAndSort(depData),\n aspects: serializeAspect(component),\n };\n }\n\n private async parseValues(values: string[]): Promise<{ bitIds: BitId[]; version?: string; toVersion?: string }> {\n if (!this.workspace) throw new OutsideWorkspaceError();\n const consumer = this.workspace.consumer;\n // option #1: bit diff\n // no arguments\n if (!values.length) {\n const componentsList = new ComponentsList(consumer);\n const bitIds = await componentsList.listTagPendingComponents();\n // @ts-ignore AUTO-ADDED-AFTER-MIGRATION-PLEASE-FIX!\n return { bitIds };\n }\n const firstValue = values[0];\n const lastValue = values[values.length - 1];\n const oneBeforeLastValue = values[values.length - 2];\n const isLastItemVersion = BitId.isValidVersion(lastValue);\n const isOneBeforeLastItemVersion = BitId.isValidVersion(oneBeforeLastValue);\n // option #2: bit diff [ids...]\n // all arguments are ids\n if (!isLastItemVersion) {\n return { bitIds: this.getBitIdsForDiff(values) };\n }\n // option #3: bit diff [id] [version]\n // last argument is a version, first argument is id\n if (!isOneBeforeLastItemVersion) {\n if (values.length !== 2) {\n throw new BitError(\n `bit diff [id] [version] syntax was used, however, ${values.length} arguments were given instead of 2`\n );\n }\n return { bitIds: this.getBitIdsForDiff([firstValue]), version: lastValue };\n }\n // option #4: bit diff [id] [version] [to_version]\n // last argument and one before the last are versions, first argument is id\n if (values.length !== 3) {\n throw new BitError(\n `bit diff [id] [version] [to_version] syntax was used, however, ${values.length} arguments were given instead of 3`\n );\n }\n return { bitIds: this.getBitIdsForDiff([firstValue]), version: oneBeforeLastValue, toVersion: lastValue };\n }\n\n private getBitIdsForDiff(ids: string[]): BitId[] {\n if (!this.workspace) throw new OutsideWorkspaceError();\n const consumer = this.workspace.consumer;\n if (hasWildcard(ids)) {\n const componentsList = new ComponentsList(consumer);\n return componentsList.listComponentsByIdsWithWildcard(ids);\n }\n return ids.map((id) => consumer.getParsedId(id));\n }\n\n static slots = [];\n static dependencies = [\n GraphqlAspect,\n ComponentAspect,\n ScopeAspect,\n LoggerAspect,\n CLIAspect,\n WorkspaceAspect,\n TesterAspect,\n DependencyResolverAspect,\n ];\n static runtime = MainRuntime;\n static async provider([graphql, component, scope, loggerMain, cli, workspace, tester, depResolver]: [\n GraphqlMain,\n ComponentMain,\n ScopeMain,\n LoggerMain,\n CLIMain,\n Workspace,\n TesterMain,\n DependencyResolverMain\n ]) {\n const logger = loggerMain.createLogger(ComponentCompareAspect.id);\n const componentCompareMain = new ComponentCompareMain(component, scope, logger, tester, depResolver, workspace);\n cli.register(new DiffCmd(componentCompareMain));\n graphql.register(componentCompareSchema(componentCompareMain));\n return componentCompareMain;\n }\n}\n\nComponentCompareAspect.addRuntime(ComponentCompareMain);\n\nexport default ComponentCompareMain;\n"],"mappings":";;;;;;AAAA,SAAAA,KAAA;EAAA,MAAAC,IAAA,GAAAC,OAAA;EAAAF,IAAA,YAAAA,CAAA;IAAA,OAAAC,IAAA;EAAA;EAAA,OAAAA,IAAA;AAAA;AACA,SAAAE,UAAA;EAAA,MAAAF,IAAA,GAAAC,OAAA;EAAAC,SAAA,YAAAA,CAAA;IAAA,OAAAF,IAAA;EAAA;EAAA,OAAAA,IAAA;AAAA;AACA,SAAAG,WAAA;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,oBAAA;AAAAlB,eAAA,CApLYkB,oBAAoB,WAwJhB,EAAE;AAAAlB,eAAA,CAxJNkB,oBAAoB,kBAyJT,CACpB0H,wBAAa,EACbC,oBAAe,EACfC,oBAAW,EACXC,sBAAY,EACZC,gBAAS,EACTC,4BAAe,EACfC,sBAAY,EACZlC,6BAAwB,CACzB;AAAAhH,eAAA,CAlKUkB,oBAAoB,aAmKdiI,kBAAW;AAmB9Bb,2CAAsB,CAACc,UAAU,CAAClI,oBAAoB,CAAC;AAAC,IAAAmI,QAAA,GAEzCnI,oBAAoB;AAAAyH,OAAA,CAAA1J,OAAA,GAAAoK,QAAA"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import * as compositions_0 from '/home/circleci/Library/Caches/Bit/capsules/8891be5ad3d35bfc38b9cd90c0e05b598a5a55af/teambit.component_component-compare@1.0.4/dist/component-compare.compositions.js';
|
|
2
|
+
import * as overview_0 from '/home/circleci/Library/Caches/Bit/capsules/8891be5ad3d35bfc38b9cd90c0e05b598a5a55af/teambit.component_component-compare@1.0.4/dist/component-compare.docs.mdx';
|
|
3
|
+
|
|
4
|
+
export const compositions = [compositions_0];
|
|
5
|
+
export const overview = [overview_0];
|
|
6
|
+
|
|
7
|
+
export const compositions_metadata = {"compositions":[{"displayName":"Logo","identifier":"Logo"}]};
|
package/package.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@teambit/component-compare",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.4",
|
|
4
4
|
"homepage": "https://bit.cloud/teambit/component/component-compare",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"componentId": {
|
|
7
7
|
"scope": "teambit.component",
|
|
8
8
|
"name": "component-compare",
|
|
9
|
-
"version": "1.0.
|
|
9
|
+
"version": "1.0.4"
|
|
10
10
|
},
|
|
11
11
|
"dependencies": {
|
|
12
12
|
"graphql-tag": "2.12.1",
|
|
@@ -16,21 +16,23 @@
|
|
|
16
16
|
"@teambit/harmony": "0.4.6",
|
|
17
17
|
"@teambit/legacy-bit-id": "1.0.0",
|
|
18
18
|
"@teambit/component.ui.component-compare.models.component-compare-change-type": "0.0.7",
|
|
19
|
-
"@teambit/component.ui.component-compare.models.component-compare-props": "0.0.
|
|
20
|
-
"@teambit/component": "1.0.
|
|
19
|
+
"@teambit/component.ui.component-compare.models.component-compare-props": "0.0.95",
|
|
20
|
+
"@teambit/component": "1.0.4",
|
|
21
21
|
"@teambit/ui-foundation.ui.menu-widget-icon": "0.0.502",
|
|
22
22
|
"@teambit/bit-error": "0.0.404",
|
|
23
|
-
"@teambit/
|
|
24
|
-
"@teambit/
|
|
25
|
-
"@teambit/
|
|
26
|
-
"@teambit/
|
|
27
|
-
"@teambit/
|
|
28
|
-
"@teambit/
|
|
29
|
-
"@teambit/
|
|
30
|
-
"@teambit/
|
|
31
|
-
"@teambit/component.ui.component-compare.
|
|
23
|
+
"@teambit/builder": "1.0.4",
|
|
24
|
+
"@teambit/cli": "0.0.786",
|
|
25
|
+
"@teambit/dependency-resolver": "1.0.4",
|
|
26
|
+
"@teambit/graphql": "1.0.4",
|
|
27
|
+
"@teambit/logger": "0.0.879",
|
|
28
|
+
"@teambit/scope": "1.0.4",
|
|
29
|
+
"@teambit/tester": "1.0.4",
|
|
30
|
+
"@teambit/workspace": "1.0.4",
|
|
31
|
+
"@teambit/component.ui.component-compare.changelog": "0.0.165",
|
|
32
|
+
"@teambit/component.ui.component-compare.compare-aspects.compare-aspects": "0.0.139",
|
|
33
|
+
"@teambit/component.ui.component-compare.component-compare": "0.0.164",
|
|
32
34
|
"@teambit/ui-foundation.ui.react-router.slot-router": "0.0.506",
|
|
33
|
-
"@teambit/ui": "1.0.
|
|
35
|
+
"@teambit/ui": "1.0.4"
|
|
34
36
|
},
|
|
35
37
|
"devDependencies": {
|
|
36
38
|
"@types/react": "^17.0.8",
|
|
@@ -43,7 +45,7 @@
|
|
|
43
45
|
},
|
|
44
46
|
"peerDependencies": {
|
|
45
47
|
"react-router-dom": "^6.0.0",
|
|
46
|
-
"@teambit/legacy": "1.0.
|
|
48
|
+
"@teambit/legacy": "1.0.568",
|
|
47
49
|
"react": "^16.8.0 || ^17.0.0",
|
|
48
50
|
"react-dom": "^16.8.0 || ^17.0.0"
|
|
49
51
|
},
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import * as compositions_0 from '/Users/davidfirst/Library/Caches/Bit/capsules/633786a8db5eb76897544549d9cae6b12f050100/teambit.component_component-compare@1.0.2/dist/component-compare.compositions.js';
|
|
2
|
-
import * as overview_0 from '/Users/davidfirst/Library/Caches/Bit/capsules/633786a8db5eb76897544549d9cae6b12f050100/teambit.component_component-compare@1.0.2/dist/component-compare.docs.mdx';
|
|
3
|
-
|
|
4
|
-
export const compositions = [compositions_0];
|
|
5
|
-
export const overview = [overview_0];
|
|
6
|
-
|
|
7
|
-
export const compositions_metadata = {"compositions":[{"displayName":"Logo","identifier":"Logo"}]};
|