private void OpenGitWebsite() { string url = "https://github.com/piotrsladowski/CoreBackup"; try { Process.Start(url); EventLogViewModel.AddNewRegistry("CoreBackup GitHub Page visited", DateTime.Now, "Git Hub", "Low"); } catch { if (RuntimeInformation.IsOSPlatform(OSPlatform.Windows)) { url = url.Replace("&", "^&"); Process.Start(new ProcessStartInfo("cmd", $"/c start {url}") { CreateNoWindow = true }); } else if (RuntimeInformation.IsOSPlatform(OSPlatform.Linux)) { Process.Start("xdg-open", url); } else if (RuntimeInformation.IsOSPlatform(OSPlatform.OSX)) { Process.Start("open", url); } else { throw; } } }
private void SyncToRightOverride() { SyncActions syncActions = new SyncActions(LeftFiles, RightFiles); syncActions.SyncToRightOverride(); EventLogViewModel.AddNewRegistry("Synchronization completed", DateTime.Now, this.GetType().Name, "HIGH"); RefreshDataGrid(); }