public App() { InitializeComponent(); ServiceLocatorInitializer.Initialize(); _activationService = new Lazy <ActivationService>(CreateActivationService); }
private static int Main(string[] args) { try { MSBuildInitializer.Initialize(); ServiceLocatorInitializer.Initialize(); #if DEBUG if (Debugger.IsAttached) { string input; do { Console.WriteLine("Waiting for user input."); input = Console.ReadLine(); if (string.IsNullOrEmpty(input)) { return(0); } Console.Clear(); var userArgs = input.Split(new[] { ' ' }, StringSplitOptions.RemoveEmptyEntries); var code = RunApplication(userArgs); Console.WriteLine(code); }while (input != "exit"); return(0); } else { return(RunApplication(args)); } #else return(RunApplication(args)); #endif } catch (Exception e) { Console.Out.WriteLine(e); LogManager.Flush(TimeSpan.FromSeconds(10)); return(-1); } }