diff --git a/source/OctopusTools/Importers/ProjectImporter.cs b/source/OctopusTools/Importers/ProjectImporter.cs index c6c4e8cc0..497e8d352 100644 --- a/source/OctopusTools/Importers/ProjectImporter.cs +++ b/source/OctopusTools/Importers/ProjectImporter.cs @@ -115,11 +115,9 @@ protected override bool Validate(Dictionary paramDictionary) if (validatedImportSettings.HasErrors) { - Log.Error("The following issues were found with the provided import file:"); - foreach (var error in validatedImportSettings.ErrorList) - { - Log.ErrorFormat(" {0}", error); - } + var errorMessagesCsvString = string.Join(Environment.NewLine, validatedImportSettings.ErrorList); + var errorMessage = string.Format($"The following issues were found with the provided import file: {Environment.NewLine}{errorMessagesCsvString}"); + throw new CommandException(errorMessage); } else {