diff --git a/src/tye/Program.cs b/src/tye/Program.cs index 319dc41d..0f0a7814 100644 --- a/src/tye/Program.cs +++ b/src/tye/Program.cs @@ -11,6 +11,7 @@ using System.CommandLine.IO; using System.CommandLine.Parsing; using System.Reflection; using System.Threading.Tasks; +using Tye.Serialization; namespace Microsoft.Tye { @@ -78,6 +79,16 @@ namespace Microsoft.Tye context.Console.Error.WriteLine(command.InnerException.ToString()); } } + else if (exception is TyeYamlException yaml) + { + context.Console.Error.WriteLine($"{yaml.Message}"); + + if (yaml.InnerException != null) + { + context.Console.Error.WriteLine(); + context.Console.Error.WriteLine(yaml.InnerException.ToString()); + } + } else { context.Console.Error.WriteLine("An unhandled exception has occurred, how unseemly: ");