/// <summary> /// Sends the revised repo back to some source repo. The assumption is that there have been changes in the rpo, using this tool, /// and that no team members have done any S/Rs, while this fixing was being done. /// /// If the one or more team members didn't get the memo to stop doing changes, then odds are high that this tool will need to be re-run. /// </summary> private void HandleSendBackToSourceMenuClick(object sender, EventArgs e) { if (string.IsNullOrWhiteSpace(_repoFolder) || _chorusSystem == null) { return; } // Send it off to some source. using (var syncDlg = (SyncDialog)_chorusSystem.WinForms.CreateSynchronizationDialog(SyncUIDialogBehaviors.Lazy, SyncUIFeatures.NormalRecommended | SyncUIFeatures.PlaySoundIfSuccessful)) { var repoType = GetRepoType(); var syncAdjunt = new RepositoryUtilitySychronizerAdjunct( (repoType == RepoType.LIFT) ? Directory.GetFiles(_repoFolder, "*.lift").First() : Path.Combine(_repoFolder, Path.GetFileName(_repoFolder) + Utilities.FwXmlExtension), repoType); syncDlg.SetSynchronizerAdjunct(syncAdjunt); // Chorus does it in this order: // Local Commit // Pull // Merge (Only if anything came in with the pull from other sources, and commit of merged results) // Push // Chorus will try the commit, as we have no way to tell Chorus to not do it. // But, there is nothing to commit, if the app user plays the game properly. // So, we do have control over the pull, merge, and push operations, and we only want to do the push. // The idea is that any other team members are idle during this business, and they have all synced up before this is done, // so we don't really need to see if someone didn't follow the 'rules', but did one more push, after we had done made the clone. // The whole point of the drill here is to nuke that other head, not to try and merge in with it. syncDlg.SyncOptions.DoPullFromOthers = false; syncDlg.SyncOptions.DoMergeWithOthers = false; syncDlg.SyncOptions.DoSendToOthers = true; syncDlg.Text = "End Game of rollback repo"; syncDlg.StartPosition = FormStartPosition.CenterScreen; syncDlg.BringToFront(); syncDlg.ShowDialog(); } }
/// <summary> /// Sends the revised repo back to some source repo. The assumption is that there have been changes in the rpo, using this tool, /// and that no team members have done any S/Rs, while this fixing was being done. /// /// If the one or more team members didn't get the memo to stop doing changes, then odds are high that this tool will need to be re-run. /// </summary> private void HandleSendBackToSourceMenuClick(object sender, EventArgs e) { if (string.IsNullOrWhiteSpace(_repoFolder) || _chorusSystem == null) return; // Send it off to some source. using (var syncDlg = (SyncDialog)_chorusSystem.WinForms.CreateSynchronizationDialog(SyncUIDialogBehaviors.Lazy, SyncUIFeatures.NormalRecommended | SyncUIFeatures.PlaySoundIfSuccessful)) { var repoType = GetRepoType(); var syncAdjunt = new RepositoryUtilitySychronizerAdjunct( (repoType == RepoType.LIFT) ? Directory.GetFiles(_repoFolder, "*.lift").First() : Path.Combine(_repoFolder, Path.GetFileName(_repoFolder) + Utilities.FwXmlExtension), repoType); syncDlg.SetSynchronizerAdjunct(syncAdjunt); // Chorus does it in this order: // Local Commit // Pull // Merge (Only if anything came in with the pull from other sources, and commit of merged results) // Push // Chorus will try the commit, as we have no way to tell Chorus to not do it. // But, there is nothing to commit, if the app user plays the game properly. // So, we do have control over the pull, merge, and push operations, and we only want to do the push. // The idea is that any other team members are idle during this business, and they have all synced up before this is done, // so we don't really need to see if someone didn't follow the 'rules', but did one more push, after we had done made the clone. // The whole point of the drill here is to nuke that other head, not to try and merge in with it. syncDlg.SyncOptions.DoPullFromOthers = false; syncDlg.SyncOptions.DoMergeWithOthers = false; syncDlg.SyncOptions.DoSendToOthers = true; syncDlg.Text = "End Game of rollback repo"; syncDlg.StartPosition = FormStartPosition.CenterScreen; syncDlg.BringToFront(); syncDlg.ShowDialog(); } }