首页
论坛
新职位
搜索论坛
什么是新的
新职位
新的个人资料帖子
最新活动
会员
目前的访客
新的个人资料帖子
搜索个人资料帖子
VB.NET社区
登录
寄存器
什么是新的
搜索
搜索
仅搜索标题
通过:
新职位
搜索论坛
Menu
Log in
Register
安装应用
安装
首页
论坛
Visual Studio .NET
.NET核心
从Visual Studio 2019中回购克隆[
[email protected]
:nodejs / node.git]不成功
您正在使用过期的浏览器。它可能无法正确显示此网站或其他网站。
您应该升级或使用
替代浏览器
.
回复主题
信息
<blockquote data-quote="Skydiver" data-source="post: 19710" data-attributes="member: 11639"><p>It's mostly a logic problem. The read stream to end on line 10 is blocking execution from reaching line 11. The correct set of operations is to wait for the app to end, and then read the output.</p><p></p><p>But it's also partly a git running from .NET Framework problem, too. For a large repository, using the "--quiet" flag seems to get things moving. If I try a small repository, I don't need the "--quiet" flag.</p><p></p><p>Anyway the following works for me:</p><p>[CODE=csharp]Process proc = new Process();</p><p>proc.StartInfo.WindowStyle = ProcessWindowStyle.Normal;</p><p>proc.StartInfo.FileName = "git.exe";</p><p>// proc.StartInfo.Arguments = "clone git@github.com:azureskydiver/Passphrase.git";</p><p>proc.StartInfo.Arguments = "clone --quiet git://github.com/nodejs/node.git";</p><p>proc.StartInfo.WindowStyle = ProcessWindowStyle.Normal;</p><p>proc.StartInfo.RedirectStandardOutput = true;</p><p>proc.StartInfo.RedirectStandardError = true;</p><p>proc.StartInfo.UseShellExecute = false;</p><p>proc.Start();</p><p>proc.WaitForExit();</p><p>string output = proc.StandardOutput.ReadToEnd().Trim();</p><p>string errors = proc.StandardError.ReadToEnd().Trim();</p><p></p><p>Console.WriteLine("Output:");</p><p>Console.WriteLine(output);</p><p></p><p>Console.WriteLine("Errors:");</p><p>Console.WriteLine(errors);[/CODE]</p></blockquote><p></p>
Insert quotes…
验证
发表回复
首页
论坛
Visual Studio .NET
.NET核心
从Visual Studio 2019中回购克隆[
[email protected]
:nodejs / node.git]不成功
本网站使用Cookie来帮助个性化内容,调整您的体验并在注册时保持登录状态。
继续使用本网站,即表示您同意我们使用cookie。
接受
了解更多…
最佳
底部