Example #1
0
        public void WriteLogsToFile(InstallInput input, IEnumerable<LogEntry> entries)
        {
            var document = EntryLogWriter.Write(entries, input.Title() + " at " + DateTime.UtcNow.ToLongDateString());
            document.WriteToFile(input.LogFileFlag);

            Console.WriteLine("Output writing to {0}", input.LogFileFlag.ToFullPath());

            if (input.OpenFlag)
            {
                document.OpenInBrowser();
            }
        }
Example #2
0
        public void WriteLogsToFile(InstallInput input, IEnumerable <LogEntry> entries)
        {
            var document = EntryLogWriter.Write(entries, input.Title() + " at " + DateTime.UtcNow.ToLongDateString());

            document.WriteToFile(input.LogFileFlag);

            Console.WriteLine("Output writing to {0}", input.LogFileFlag.ToFullPath());

            if (input.OpenFlag)
            {
                document.OpenInBrowser();
            }
        }
Example #3
0
        private void logEntries(InstallInput input, IEnumerable <LogEntry> entries)
        {
            _logger.WriteLogsToConsole(entries);
            _logger.WriteLogsToFile(input, entries);

            if (entries.Any(x => !x.Success))
            {
                _logger.WriteFailureToConsole();
            }
            else
            {
                _logger.WriteSuccessToConsole();
            }
        }
        private void logEntries(InstallInput input, IEnumerable<LogEntry> entries)
        {
            _logger.WriteLogsToConsole(entries);
            _logger.WriteLogsToFile(input, entries);

            if (entries.Any(x => !x.Success))
            {
                _logger.WriteFailureToConsole();
            }
            else
            {
                _logger.WriteSuccessToConsole();
            }
        }
Example #5
0
        private IEnumerable <LogEntry> execute(InstallInput input)
        {
            Console.WriteLine(input.Title());

            switch (input.ModeFlag)
            {
            case InstallMode.install:
                return(_gateway.Install());

            case InstallMode.check:
                return(_gateway.CheckEnvironment());

            case InstallMode.all:
                return(_gateway.InstallAndCheckEnvironment());
            }

            return(new LogEntry[0]);
        }
        private IEnumerable<LogEntry> execute(InstallInput input)
        {
            Console.WriteLine(input.Title());

            switch (input.ModeFlag)
            {
                case InstallMode.install:
                    return _gateway.Install();

                case InstallMode.check:
                    return _gateway.CheckEnvironment();

                case InstallMode.all:
                    return _gateway.InstallAndCheckEnvironment();
            }

            return new LogEntry[0];
        }
Example #7
0
        // TODO -- this needs to fail!
        public void RunTheInstallation(InstallInput input)
        {
            var entries = execute(input);

            logEntries(input, entries);
        }
 // TODO -- this needs to fail!
 public void RunTheInstallation(InstallInput input)
 {
     var entries = execute(input);
     logEntries(input, entries);
 }