Skip to content

Commit 72c777b

Browse files
cjk7989Jikun
andauthored
fix: filter same framework name in e2e (Azure#722)
Co-authored-by: Jikun <jikunchen@microsoft.com>
1 parent f1dd587 commit 72c777b

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

src/core/frameworks/detect.ts

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -388,6 +388,14 @@ export function printSupportedFrameworks(showList = false): void {
388388
export function formatDetectedFolders(folders: DetectedFolder[], type: string): string {
389389
return (
390390
`Detected ${type} folders (${folders.length}):\n` +
391-
`- ${folders.map((f) => `${f.rootPath} (${f.frameworks.map((fr) => fr.name).join(", ")})`).join("\n- ")}`
391+
`- ${folders
392+
.map(
393+
(f) =>
394+
`${f.rootPath} (${f.frameworks
395+
.map((fr) => fr.name)
396+
.filter((frname, index, array) => array.indexOf(frname) === index)
397+
.join(", ")})`
398+
)
399+
.join("\n- ")}`
392400
);
393401
}

0 commit comments

Comments
 (0)