2021-11-19 22:30:23 +02:00
|
|
|
|
#region Usings
|
|
|
|
|
using NLog;
|
2021-11-13 22:56:56 +02:00
|
|
|
|
using System;
|
2022-06-02 21:54:02 +03:00
|
|
|
|
using System.IO;
|
2021-06-04 22:58:40 +03:00
|
|
|
|
using System.Windows.Forms;
|
2021-11-19 22:30:23 +02:00
|
|
|
|
#endregion
|
2021-06-04 22:58:40 +03:00
|
|
|
|
|
2021-09-02 02:35:20 +03:00
|
|
|
|
namespace Novetus.Bootstrapper
|
2021-06-04 22:58:40 +03:00
|
|
|
|
{
|
|
|
|
|
static class NovetusLaunch
|
|
|
|
|
{
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// The main entry point for the application.
|
|
|
|
|
/// </summary>
|
|
|
|
|
[STAThread]
|
|
|
|
|
static void Main()
|
|
|
|
|
{
|
|
|
|
|
Application.EnableVisualStyles();
|
|
|
|
|
Application.SetCompatibleTextRenderingDefault(false);
|
2021-11-13 22:56:56 +02:00
|
|
|
|
|
2022-06-02 21:54:02 +03:00
|
|
|
|
if (!Directory.Exists(LocalPaths.FixedLogDir))
|
|
|
|
|
{
|
|
|
|
|
Directory.CreateDirectory(LocalPaths.FixedLogDir);
|
|
|
|
|
}
|
|
|
|
|
|
2021-11-13 22:56:56 +02:00
|
|
|
|
var config = new NLog.Config.LoggingConfiguration();
|
2022-06-02 21:54:02 +03:00
|
|
|
|
var logfile = new NLog.Targets.FileTarget("logfile") { FileName = LocalPaths.FixedLogDir + "\\Bootstrapper-log-" + DateTime.Today.ToString("MM-dd-yyyy") + ".log" };
|
2021-11-13 22:56:56 +02:00
|
|
|
|
config.AddRuleForAllLevels(logfile);
|
|
|
|
|
LogManager.Configuration = config;
|
|
|
|
|
|
2021-06-04 22:58:40 +03:00
|
|
|
|
Application.Run(new NovetusLaunchForm());
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|