Skip to content

Commit e122e72

Browse files
committed
fix: always display the "no main/default" warning even in dry-run
1 parent 13462f0 commit e122e72

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

src/commands/project/convert/source-behavior.ts

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -65,11 +65,12 @@ export default class ConvertSourceBehavior extends SfCommand<SourceBehaviorResul
6565
getPackageDirectoriesForPreset(this.project!, flags.behavior),
6666
]);
6767

68+
if (!packageDirsWithDecomposable.every(hasMainDefault(this.project!.getPath()))) {
69+
this.warn(messages.getMessage('mainDefaultConfirmation'));
70+
}
71+
6872
if (!flags['dry-run']) {
6973
this.warn(messages.getMessage('basicConfirmation'));
70-
if (!packageDirsWithDecomposable.every(hasMainDefault(this.project!.getPath()))) {
71-
this.warn(messages.getMessage('mainDefaultConfirmation'));
72-
}
7374
await this.confirm({ message: 'Proceed' });
7475
}
7576
const filesToDelete = await convertToMdapi(packageDirsWithDecomposable);

0 commit comments

Comments
 (0)