当前位置: 首页>>代码示例>>C#>>正文


C# Util.ProcessArgumentBuilder类代码示例

本文整理汇总了C#中ThoughtWorks.CruiseControl.Core.Util.ProcessArgumentBuilder的典型用法代码示例。如果您正苦于以下问题:C# ProcessArgumentBuilder类的具体用法?C# ProcessArgumentBuilder怎么用?C# ProcessArgumentBuilder使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


ProcessArgumentBuilder类属于ThoughtWorks.CruiseControl.Core.Util命名空间,在下文中一共展示了ProcessArgumentBuilder类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: GetLoggerArgs

 private string GetLoggerArgs(IIntegrationResult result)
 {
     ProcessArgumentBuilder builder = new ProcessArgumentBuilder();
     builder.Append("/l:");
     builder.Append(Logger);
     builder.Append(";");
     builder.Append(MsBuildOutputFile(result));
     return builder.ToString();
 }
开发者ID:vardars,项目名称:ci-factory,代码行数:9,代码来源:MsBuildTask.cs

示例2: RunSvnProcess

        public static ProcessResult RunSvnProcess(SvnOptions svnLoginOptions, ProcessArgumentBuilder argBuilder)
        {
            argBuilder.AddArgument("--non-interactive");
            argBuilder.AddArgument("--no-auth-cache");

            ProcessInfo info = new ProcessInfo("svn.exe", argBuilder.ToString());

            ProcessExecutor executor = new ProcessExecutor();
            ProcessResult result = executor.Execute(info);
            return result;
        }
开发者ID:nfrey,项目名称:qreal,代码行数:11,代码来源:SvnProcessHelper.cs

示例3: ToString

        public override string ToString()
        {
            ProcessArgumentBuilder argsBuilder = new ProcessArgumentBuilder();
            argsBuilder.AddArgument("/xml", "=", outputfile);
            argsBuilder.AddArgument("/nologo");

            foreach (string assemblyName in assemblies)
            {
                argsBuilder.AddArgument(assemblyName);
            }
            return argsBuilder.ToString();
        }
开发者ID:vardars,项目名称:ci-factory,代码行数:12,代码来源:NUnitArgument.cs

示例4: AppendCategoriesArg

 /// <summary>
 /// Appends the categories, with value not an empty string nor a whitespace,
 /// to the excluded or included categories lists.
 /// </summary>
 /// <param name="argsBuilder">The args builder.</param>
 private void AppendCategoriesArg(ProcessArgumentBuilder argsBuilder)
 {
     if (ExcludedCategories != null && ExcludedCategories.Length != 0)
     {
         string[] excludedCategories = System.Array.FindAll(ExcludedCategories, IsNotWhitespace);
         argsBuilder.AddArgument("/exclude", "=", string.Join(",", excludedCategories));
     }
     if (IncludedCategories != null && IncludedCategories.Length != 0)
     {
         string[] includedCategories = System.Array.FindAll(IncludedCategories, IsNotWhitespace);
         argsBuilder.AddArgument("/include", "=", string.Join(",", includedCategories));
     }
 }
开发者ID:derrills1,项目名称:ccnet_gitmode,代码行数:18,代码来源:NUnitArgument.cs

示例5: Args

        private string Args(IIntegrationResult result)
        {
            ProcessArgumentBuilder builder = new ProcessArgumentBuilder();

            builder.AddArgument("/nologo");
            if (! StringUtil.IsBlank(Targets)) builder.AddArgument("/t:" + Targets);
            builder.AddArgument(GetPropertyArgs(result));
            builder.AppendArgument(BuildArgs);
            builder.AddArgument(ProjectFile);
            builder.AddArgument(GetLoggerArgs(result));

            return builder.ToString();
        }
开发者ID:vardars,项目名称:ci-factory,代码行数:13,代码来源:MsBuildTask.cs

示例6: GetSvnRevision

        public static int GetSvnRevision(SvnOptions svnOptions)
        {
            ProcessArgumentBuilder argBuilder = new ProcessArgumentBuilder();
            argBuilder.AppendArgument("log");
            argBuilder.AppendArgument("--xml");
            argBuilder.AppendArgument("--limit 1");
            argBuilder.AddArgument(StringHelper.Quote(svnOptions.Url));
            ProcessResult result = RunSvnProcess(svnOptions, argBuilder);

            XmlDocument xml = new XmlDocument();
            xml.LoadXml(result.StandardOutput);

            XmlNode node = xml.SelectSingleNode("/log/logentry/@revision");
            return Convert.ToInt32(node.InnerText);
        }
开发者ID:nfrey,项目名称:qreal,代码行数:15,代码来源:SvnProcessHelper.cs

示例7: BuildPushProcessArgs

 private string BuildPushProcessArgs()
 {
     ProcessArgumentBuilder buffer = new ProcessArgumentBuilder();
     buffer.AppendArgument("push");
     return buffer.ToString();
 }
开发者ID:derrills1,项目名称:ccnet_gitmode,代码行数:6,代码来源:BitKeeper.cs

示例8: BuildGetSourceArguments

 private string BuildGetSourceArguments()
 {
     ProcessArgumentBuilder buffer = new ProcessArgumentBuilder();
     buffer.Append("pull");
     return buffer.ToString();
 }
开发者ID:derrills1,项目名称:ccnet_gitmode,代码行数:6,代码来源:BitKeeper.cs

示例9: RemoveReadOnlyAttribute

 private void RemoveReadOnlyAttribute()
 {
     ProcessArgumentBuilder buffer = new ProcessArgumentBuilder();
     buffer.AddArgument("-R");
     buffer.AddArgument("/s", SandboxRoot + "\\*");
     Execute(new ProcessInfo("attrib", buffer.ToString()));
 }
开发者ID:derrills1,项目名称:ccnet_gitmode,代码行数:7,代码来源:Mks.cs

示例10: BuildResyncCommand

 //RESYNC_TEMPLATE = "resync --overwriteChanged --restoreTimestamp-R -S {SandboxRoot\SandboxFile} --user={user} --password={password} --quiet"
 private string BuildResyncCommand()
 {
     ProcessArgumentBuilder buffer = new ProcessArgumentBuilder();
     buffer.AppendArgument("resync");
     buffer.AppendArgument("--overwriteChanged");
     buffer.AppendArgument("--restoreTimestamp");
     buffer.AppendArgument("--forceConfirm=yes");
     buffer.AppendArgument("--includeDropped");
     AppendCommonArguments(buffer, true);
     return buffer.ToString();
 }
开发者ID:derrills1,项目名称:ccnet_gitmode,代码行数:12,代码来源:Mks.cs

示例11: BuildDisconnectCommand

 private string BuildDisconnectCommand()
 {
     ProcessArgumentBuilder buffer = new ProcessArgumentBuilder();
     buffer.AppendArgument("disconnect");
     buffer.AppendArgument("--user={0}", User);
     buffer.AppendArgument("--password={0}", Password);
     buffer.AppendArgument("--quiet");
     buffer.AppendArgument("--forceConfirm=yes");
     return buffer.ToString();
 }
开发者ID:derrills1,项目名称:ccnet_gitmode,代码行数:10,代码来源:Mks.cs

示例12: AppendCommonArguments

        private void AppendCommonArguments(ProcessArgumentBuilder buffer, bool recurse, bool omitSandbox)
        {
            if (recurse)
            {
                buffer.AppendArgument("-R");
            }

            if (!omitSandbox)
            {
                buffer.AddArgument("-S", Path.Combine(SandboxRoot, SandboxFile));
            }

            buffer.AppendArgument("--user={0}", User);
            buffer.AppendArgument("--password={0}", Password);
            buffer.AppendArgument("--quiet");
        }
开发者ID:derrills1,项目名称:ccnet_gitmode,代码行数:16,代码来源:Mks.cs

示例13: GitConfigGet

		/// <summary>
		/// Call "git config --get 'name'" to get the value of a local repository property.
        /// The command returns error code 1 if the key was not found and error code 2 if multiple key values were found. 
		/// </summary>
		/// <param name="name">Name of the config parameter.</param>
		/// <param name="result">IIntegrationResult of the current build.</param>
		/// <returns>Result of the "git config --get 'name'" command.</returns>
        private string GitConfigGet(string name, IIntegrationResult result)
		{
		    ProcessArgumentBuilder buffer = new ProcessArgumentBuilder();
		    buffer.AddArgument("config");
		    buffer.AddArgument("--get");
		    buffer.AddArgument(name);
		    return
		        Execute(NewProcessInfo(buffer.ToString(), result, ProcessPriorityClass.Normal, new int[] {0, 1, 2})).
		            StandardOutput.Trim();
		}
开发者ID:josemarcenaro,项目名称:CruiseControl.NET,代码行数:17,代码来源:Git.cs

示例14: GitConfigSet

		/// <summary>
		/// Call "git config 'name' 'value'" to set local repository properties.
		/// </summary>
		/// <param name="name">Name of the config parameter.</param>
		/// <param name="value">Value of the config parameter.</param>
		/// <param name="result">IIntegrationResult of the current build.</param>
		private void GitConfigSet(string name, string value, IIntegrationResult result)
		{
			ProcessArgumentBuilder buffer = new ProcessArgumentBuilder();
			buffer.AddArgument("config");
			buffer.AddArgument(name);
			buffer.AddArgument(value);
			Execute(NewProcessInfo(buffer.ToString(), result));
		}
开发者ID:josemarcenaro,项目名称:CruiseControl.NET,代码行数:14,代码来源:Git.cs

示例15: GitClone

		/// <summary>
		/// Clone a repository into a new directory with "git clone 'repository' 'working directory'".
		/// </summary>
		/// <param name="result">IIntegrationResult of the current build.</param>
		private void GitClone(IIntegrationResult result)
		{
			string wd = BaseWorkingDirectory(result);

			ProcessArgumentBuilder buffer = new ProcessArgumentBuilder();
			buffer.AddArgument("clone");
			buffer.AddArgument(Repository);
			buffer.AddArgument(wd);

			// initialize progress information
			var bpi = GetBuildProgressInformation(result);
			bpi.SignalStartRunTask(string.Concat("git ", buffer.ToString()));

			// enable Stdout monitoring
			ProcessExecutor.ProcessOutput += ProcessExecutor_ProcessOutput;

			ProcessInfo pi = NewProcessInfo(buffer.ToString(), result);
			// Use upper level of the working directory, because the
			// working directory currently does not exist and
			// will be created by "git clone". "git clone" will fail if
			// the working directory already exist.
			pi.WorkingDirectory = Path.GetDirectoryName(wd.Trim().TrimEnd(Path.DirectorySeparatorChar));
			Execute(pi);

			// remove Stdout monitoring
			ProcessExecutor.ProcessOutput -= ProcessExecutor_ProcessOutput;
		}
开发者ID:josemarcenaro,项目名称:CruiseControl.NET,代码行数:31,代码来源:Git.cs


注:本文中的ThoughtWorks.CruiseControl.Core.Util.ProcessArgumentBuilder类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。