本文整理汇总了C#中GitCommands.GitModule.GetPathSetting方法的典型用法代码示例。如果您正苦于以下问题:C# GitModule.GetPathSetting方法的具体用法?C# GitModule.GetPathSetting怎么用?C# GitModule.GetPathSetting使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类GitCommands.GitModule
的用法示例。
在下文中一共展示了GitModule.GetPathSetting方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: RunScript
//.........这里部分代码省略.........
break;
case "{sRemoteBranch}":
if (selectedRemoteBranches.Count == 1)
argument = argument.Replace(option, selectedRemoteBranches[0].Name);
else if (selectedRemoteBranches.Count != 0)
argument = argument.Replace(option,
askToSpecify(selectedRemoteBranches,
"Selected Revision Remote Branch"));
else
argument = argument.Replace(option, "");
break;
case "{sRemote}":
if (selectedRemotes.Count == 0)
{
argument = argument.Replace(option, "");
break;
}
if (selectedRemotes.Count == 1)
remote = selectedRemotes[0];
else
remote = askToSpecify(selectedRemotes, "Selected Revision Remote");
argument = argument.Replace(option, remote);
break;
case "{sRemoteUrl}":
if (selectedRemotes.Count == 0)
{
argument = argument.Replace(option, "");
break;
}
if (selectedRemotes.Count == 1)
remote = selectedRemotes[0];
else
remote = askToSpecify(selectedRemotes, "Selected Revision Remote");
url = aModule.GetPathSetting(string.Format(SettingKeyString.RemoteUrl, remote));
argument = argument.Replace(option, url);
break;
case "{sRemotePathFromUrl}":
if (selectedRemotes.Count == 0)
{
argument = argument.Replace(option, "");
break;
}
if (selectedRemotes.Count == 1)
remote = selectedRemotes[0];
else
remote = askToSpecify(selectedRemotes, "Selected Revision Remote");
url = aModule.GetPathSetting(string.Format(SettingKeyString.RemoteUrl, remote));
argument = argument.Replace(option, GetRemotePath(url));
break;
case "{sHash}":
argument = argument.Replace(option, selectedRevision.Guid);
break;
case "{sMessage}":
argument = argument.Replace(option, selectedRevision.Message);
break;
case "{sAuthor}":
argument = argument.Replace(option, selectedRevision.Author);
break;
case "{sCommitter}":
argument = argument.Replace(option, selectedRevision.Committer);
break;
case "{sAuthorDate}":
argument = argument.Replace(option, selectedRevision.AuthorDate.ToString());
break;
case "{sCommitDate}":
argument = argument.Replace(option, selectedRevision.CommitDate.ToString());
示例2: RunScript
//.........这里部分代码省略.........
break;
case "{sRemoteBranch}":
if (selectedRemoteBranches.Count == 1)
argument = argument.Replace(option, selectedRemoteBranches[0].Name);
else if (selectedRemoteBranches.Count != 0)
argument = argument.Replace(option,
askToSpecify(selectedRemoteBranches,
"Selected Revision Remote Branch"));
else
argument = argument.Replace(option, "");
break;
case "{sRemote}":
if (selectedRemotes.Count == 0)
{
argument = argument.Replace(option, "");
break;
}
if (selectedRemotes.Count == 1)
remote = selectedRemotes[0];
else
remote = askToSpecify(selectedRemotes, "Selected Revision Remote");
argument = argument.Replace(option, remote);
break;
case "{sRemoteUrl}":
if (selectedRemotes.Count == 0)
{
argument = argument.Replace(option, "");
break;
}
if (selectedRemotes.Count == 1)
remote = selectedRemotes[0];
else
remote = askToSpecify(selectedRemotes, "Selected Revision Remote");
url = aModule.GetPathSetting(string.Format(SettingKeyString.RemoteUrl, remote));
argument = argument.Replace(option, url);
break;
case "{sRemotePathFromUrl}":
if (selectedRemotes.Count == 0)
{
argument = argument.Replace(option, "");
break;
}
if (selectedRemotes.Count == 1)
remote = selectedRemotes[0];
else
remote = askToSpecify(selectedRemotes, "Selected Revision Remote");
url = aModule.GetPathSetting(string.Format(SettingKeyString.RemoteUrl, remote));
argument = argument.Replace(option, GetRemotePath(url));
break;
case "{sHash}":
argument = argument.Replace(option, selectedRevision.Guid);
break;
case "{sMessage}":
argument = argument.Replace(option, selectedRevision.Message);
break;
case "{sAuthor}":
argument = argument.Replace(option, selectedRevision.Author);
break;
case "{sCommitter}":
argument = argument.Replace(option, selectedRevision.Committer);
break;
case "{sAuthorDate}":
argument = argument.Replace(option, selectedRevision.AuthorDate.ToString());
break;
case "{sCommitDate}":
argument = argument.Replace(option, selectedRevision.CommitDate.ToString());