コード例 #1
0
        public static bool AskForCacheHostkey(IWin32Window owner, GitModule module, string remoteUrl)
        {
            if (!remoteUrl.IsNullOrEmpty() && MessageBoxes.CacheHostkey(owner))
            {
                remoteUrl = GitCommandHelpers.GetPlinkCompatibleUrl(remoteUrl);

                module.RunExternalCmdShowConsole(
                    "cmd.exe",
                    string.Format("/k \"\"{0}\" -T \"{1}\"\"", AppSettings.Plink, remoteUrl));

                return(true);
            }

            return(false);
        }
コード例 #2
0
        private bool RequiredValidGitSvnWorikingDir(object owner)
        {
            if (!RequiresValidWorkingDir(owner))
            {
                return(false);
            }

            if (!GitSvnCommandHelpers.ValidSvnWorkingDir())
            {
                MessageBoxes.NotValidGitSVNDirectory(owner as IWin32Window);
                return(false);
            }

            if (!GitSvnCommandHelpers.CheckRefsRemoteSvn())
            {
                MessageBoxes.UnableGetSVNInformation(owner as IWin32Window);
                return(false);
            }

            return(true);
        }
コード例 #3
0
        private static void SolveMergeConflicts(GitUICommands aCommands, IWin32Window owner, bool offerCommit)
        {
            if (aCommands.Module.InTheMiddleOfConflictedMerge())
            {
                aCommands.StartResolveConflictsDialog(owner, offerCommit);
            }

            if (aCommands.Module.InTheMiddleOfPatch())
            {
                if (MessageBoxes.MiddleOfPatchApply(owner))
                {
                    aCommands.StartApplyPatchDialog(owner);
                }
            }
            else if (aCommands.Module.InTheMiddleOfRebase())
            {
                if (MessageBoxes.MiddleOfRebase(owner))
                {
                    aCommands.StartRebaseDialog(owner, null);
                }
            }
        }