예제 #1
0
        static void Main(string[] args)
        {
            LogHelper.InitLogPath();
            LogHelper.AddLog("Instance is starting.");

            var list = HardwareHelper.GetCpuId();

            list.ForEach(Console.WriteLine);

            var disks = HardwareHelper.GetRemovableDisk();

            disks.ForEach(Console.WriteLine);

            AppDomain.CurrentDomain.ProcessExit += (sender, eventArgs) =>
            {
                _instanceMutex?.ReleaseMutex();
                _instanceMutex = null;
                LogHelper.AddLog("Instance is shutting down.");
            };

            CheckSingleInstance();
            AddThreadExceptionHandler();

            GlobalConfig.Instance.Init();

            Run();
        }
예제 #2
0
 public void GetCpuId()
 {
     var code = HardwareHelper.GetCpuId();
 }