Skip to content

Commit

Permalink
chore: comments
Browse files Browse the repository at this point in the history
  • Loading branch information
WillieRuemmele committed Oct 30, 2023
1 parent 0239392 commit 3036227
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions src/convert/transformers/decomposedMetadataTransformer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -130,11 +130,17 @@ export class DecomposedMetadataTransformer extends BaseMetadataTransformer {
}
// if no child component is found to merge with yet, mark it as so in the state
else if (!this.getDecomposedState(childComponent)?.foundMerge) {
// if the child can't exist without the parent, redirect the output to the parents output, rather than the default output
if (mergeWith?.content && childComponent.type.unaddressableWithoutParent && childComponent.type.suffix) {
// if the child can't exist without the parent, and we found a parent (mergeWith) redirect the output to the parents output, rather than the default output
writeInfos.push({
source,
output: path.join(mergeWith.content, entryName + '.' + childComponent.type.suffix + '-meta.xml'),
output: path.join(mergeWith.content, `${entryName}.${childComponent.type.suffix}${META_XML_SUFFIX}`),
});
} else if (!mergeWith) {
// if the child can't exist without a parent, and there's no parent found, redirect to the default pkg dir
writeInfos.push({
source,
output: getDefaultOutput(childComponent),
});
} else {
this.setDecomposedState(childComponent, {
Expand Down

2 comments on commit 3036227

@svc-cli-bot
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Benchmark

Benchmark suite Current: 3036227 Previous: 601aed3 Ratio
eda-componentSetCreate-linux 239 ms 259 ms 0.92
eda-sourceToMdapi-linux 7973 ms 5113 ms 1.56
eda-sourceToZip-linux 5618 ms 4580 ms 1.23
eda-mdapiToSource-linux 3320 ms 4075 ms 0.81
lotsOfClasses-componentSetCreate-linux 506 ms 468 ms 1.08
lotsOfClasses-sourceToMdapi-linux 8450 ms 6065 ms 1.39
lotsOfClasses-sourceToZip-linux 6849 ms 5924 ms 1.16
lotsOfClasses-mdapiToSource-linux 3450 ms 3259 ms 1.06
lotsOfClassesOneDir-componentSetCreate-linux 730 ms 749 ms 0.97
lotsOfClassesOneDir-sourceToMdapi-linux 10610 ms 8631 ms 1.23
lotsOfClassesOneDir-sourceToZip-linux 10616 ms 8953 ms 1.19
lotsOfClassesOneDir-mdapiToSource-linux 5595 ms 5894 ms 0.95

This comment was automatically generated by workflow using github-action-benchmark.

@svc-cli-bot
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Benchmark

Benchmark suite Current: 3036227 Previous: 601aed3 Ratio
eda-componentSetCreate-win32 432 ms 579 ms 0.75
eda-sourceToMdapi-win32 8132 ms 8286 ms 0.98
eda-sourceToZip-win32 6505 ms 6896 ms 0.94
eda-mdapiToSource-win32 6615 ms 9379 ms 0.71
lotsOfClasses-componentSetCreate-win32 999 ms 1270 ms 0.79
lotsOfClasses-sourceToMdapi-win32 13479 ms 15501 ms 0.87
lotsOfClasses-sourceToZip-win32 8028 ms 10416 ms 0.77
lotsOfClasses-mdapiToSource-win32 8693 ms 11203 ms 0.78
lotsOfClassesOneDir-componentSetCreate-win32 1626 ms 2141 ms 0.76
lotsOfClassesOneDir-sourceToMdapi-win32 19425 ms 23828 ms 0.82
lotsOfClassesOneDir-sourceToZip-win32 12260 ms 16674 ms 0.74
lotsOfClassesOneDir-mdapiToSource-win32 14950 ms 20684 ms 0.72

This comment was automatically generated by workflow using github-action-benchmark.

Please sign in to comment.