From d3143b779f399e9be37d98d69b9b0c6cec25a3ef Mon Sep 17 00:00:00 2001 From: Jon Sequeira Date: Sun, 12 Mar 2017 16:48:59 -0700 Subject: [PATCH] stop writing ParseResult.Diagram to output --- src/dotnet/DotNetTopLevelCommandBase.cs | 2 -- src/dotnet/commands/dotnet-build/BuildCommand.cs | 2 -- src/dotnet/commands/dotnet-cache/Program.cs | 2 -- src/dotnet/commands/dotnet-clean/Program.cs | 2 -- src/dotnet/commands/dotnet-migrate/Program.cs | 2 -- src/dotnet/commands/dotnet-pack/PackCommand.cs | 2 -- src/dotnet/commands/dotnet-publish/Program.cs | 2 -- src/dotnet/commands/dotnet-restore/Program.cs | 2 -- src/dotnet/commands/dotnet-run/Program.cs | 2 -- src/dotnet/commands/dotnet-test/Program.cs | 2 -- test/dotnet-msbuild.Tests/GivenDotnetPublishInvocation.cs | 2 -- test/dotnet.Tests/ParserTests/AddReferenceParserTests.cs | 4 ---- test/dotnet.Tests/ParserTests/RestoreParserTests.cs | 4 ---- 13 files changed, 30 deletions(-) diff --git a/src/dotnet/DotNetTopLevelCommandBase.cs b/src/dotnet/DotNetTopLevelCommandBase.cs index 319c66523..f1469da2b 100644 --- a/src/dotnet/DotNetTopLevelCommandBase.cs +++ b/src/dotnet/DotNetTopLevelCommandBase.cs @@ -25,8 +25,6 @@ namespace Microsoft.DotNet.Cli var result = parser.ParseFrom($"dotnet {CommandName}", args); - Reporter.Output.WriteLine(result.Diagram()); - result.ShowHelpIfRequested(); var subcommandName = result.Command().Name; diff --git a/src/dotnet/commands/dotnet-build/BuildCommand.cs b/src/dotnet/commands/dotnet-build/BuildCommand.cs index 3ecd6eeba..aef57ebb4 100644 --- a/src/dotnet/commands/dotnet-build/BuildCommand.cs +++ b/src/dotnet/commands/dotnet-build/BuildCommand.cs @@ -25,8 +25,6 @@ namespace Microsoft.DotNet.Tools.Build var result = parser.ParseFrom("dotnet build", args); - Reporter.Output.WriteLine(result.Diagram()); - result.ShowHelpIfRequested(); var appliedBuildOptions = result["dotnet"]["build"]; diff --git a/src/dotnet/commands/dotnet-cache/Program.cs b/src/dotnet/commands/dotnet-cache/Program.cs index 2a1a6ec19..3eb78e3da 100644 --- a/src/dotnet/commands/dotnet-cache/Program.cs +++ b/src/dotnet/commands/dotnet-cache/Program.cs @@ -29,8 +29,6 @@ namespace Microsoft.DotNet.Tools.Cache var result = parser.ParseFrom("dotnet cache", args); - Reporter.Output.WriteLine(result.Diagram()); - result.ShowHelpIfRequested(); var appliedBuildOptions = result["dotnet"]["cache"]; diff --git a/src/dotnet/commands/dotnet-clean/Program.cs b/src/dotnet/commands/dotnet-clean/Program.cs index 5963d7048..bcedf9501 100644 --- a/src/dotnet/commands/dotnet-clean/Program.cs +++ b/src/dotnet/commands/dotnet-clean/Program.cs @@ -25,8 +25,6 @@ namespace Microsoft.DotNet.Tools.Clean var result = parser.ParseFrom("dotnet clean", args); - Reporter.Output.WriteLine(result.Diagram()); - result.ShowHelpIfRequested(); var parsedClean = result["dotnet"]["clean"]; diff --git a/src/dotnet/commands/dotnet-migrate/Program.cs b/src/dotnet/commands/dotnet-migrate/Program.cs index 7c0fcb635..ce406290c 100644 --- a/src/dotnet/commands/dotnet-migrate/Program.cs +++ b/src/dotnet/commands/dotnet-migrate/Program.cs @@ -20,8 +20,6 @@ namespace Microsoft.DotNet.Tools.Migrate var result = parser.ParseFrom("dotnet migrate", args); - Reporter.Output.WriteLine(result.Diagram()); - result.ShowHelpIfRequested(); return result["dotnet"]["migrate"].Value(); diff --git a/src/dotnet/commands/dotnet-pack/PackCommand.cs b/src/dotnet/commands/dotnet-pack/PackCommand.cs index 00b8e2d68..37f4dbe61 100644 --- a/src/dotnet/commands/dotnet-pack/PackCommand.cs +++ b/src/dotnet/commands/dotnet-pack/PackCommand.cs @@ -24,8 +24,6 @@ namespace Microsoft.DotNet.Tools.Pack var result = parser.ParseFrom("dotnet pack", args); - Reporter.Output.WriteLine(result.Diagram()); - result.ShowHelpIfRequested(); var parsedPack = result["dotnet"]["pack"]; diff --git a/src/dotnet/commands/dotnet-publish/Program.cs b/src/dotnet/commands/dotnet-publish/Program.cs index 6ba893605..8a556f5fa 100644 --- a/src/dotnet/commands/dotnet-publish/Program.cs +++ b/src/dotnet/commands/dotnet-publish/Program.cs @@ -27,8 +27,6 @@ namespace Microsoft.DotNet.Tools.Publish var result = parser.ParseFrom("dotnet publish", args); - Reporter.Output.WriteLine(result.Diagram()); - result.ShowHelpIfRequested(); msbuildArgs.Add("/t:Publish"); diff --git a/src/dotnet/commands/dotnet-restore/Program.cs b/src/dotnet/commands/dotnet-restore/Program.cs index 1d34a40e1..01b456109 100644 --- a/src/dotnet/commands/dotnet-restore/Program.cs +++ b/src/dotnet/commands/dotnet-restore/Program.cs @@ -29,8 +29,6 @@ namespace Microsoft.DotNet.Tools.Restore var result = parser.ParseFrom("dotnet restore", args); - Reporter.Output.WriteLine(result.Diagram()); - result.ShowHelpIfRequested(); var parsedRestore = result["dotnet"]["restore"]; diff --git a/src/dotnet/commands/dotnet-run/Program.cs b/src/dotnet/commands/dotnet-run/Program.cs index a795b455b..016aa5422 100644 --- a/src/dotnet/commands/dotnet-run/Program.cs +++ b/src/dotnet/commands/dotnet-run/Program.cs @@ -17,8 +17,6 @@ namespace Microsoft.DotNet.Tools.Run var result = parser.ParseFrom("dotnet run", args); - Reporter.Output.WriteLine(result.Diagram()); - result.ShowHelpIfRequested(); return result["dotnet"]["run"].Value(); diff --git a/src/dotnet/commands/dotnet-test/Program.cs b/src/dotnet/commands/dotnet-test/Program.cs index 24b69cc9a..563b86be3 100644 --- a/src/dotnet/commands/dotnet-test/Program.cs +++ b/src/dotnet/commands/dotnet-test/Program.cs @@ -34,8 +34,6 @@ namespace Microsoft.DotNet.Tools.Test var result = parser.ParseFrom("dotnet test", args); - Reporter.Output.WriteLine(result.Diagram()); - result.ShowHelpIfRequested(); var parsedTest = result["dotnet"]["test"]; diff --git a/test/dotnet-msbuild.Tests/GivenDotnetPublishInvocation.cs b/test/dotnet-msbuild.Tests/GivenDotnetPublishInvocation.cs index f577f827f..61088797c 100644 --- a/test/dotnet-msbuild.Tests/GivenDotnetPublishInvocation.cs +++ b/test/dotnet-msbuild.Tests/GivenDotnetPublishInvocation.cs @@ -71,8 +71,6 @@ namespace Microsoft.DotNet.Cli.MSBuild.Tests var result = parser.ParseFrom("dotnet publish", args); - output.WriteLine(result.Diagram()); - result["dotnet"]["publish"] .OptionValuesToBeForwarded() .Should() diff --git a/test/dotnet.Tests/ParserTests/AddReferenceParserTests.cs b/test/dotnet.Tests/ParserTests/AddReferenceParserTests.cs index 68121383d..2aa5beec8 100644 --- a/test/dotnet.Tests/ParserTests/AddReferenceParserTests.cs +++ b/test/dotnet.Tests/ParserTests/AddReferenceParserTests.cs @@ -29,8 +29,6 @@ namespace Microsoft.DotNet.Tests.ParserTests var result = command.Parse("dotnet add reference my.csproj"); - output.WriteLine(result.Diagram()); - result["dotnet"]["add"] .Arguments .Should() @@ -45,8 +43,6 @@ namespace Microsoft.DotNet.Tests.ParserTests var result = command.Parse("dotnet add reference"); - output.WriteLine(result.Diagram()); - result .Errors .Select(e => e.Message) diff --git a/test/dotnet.Tests/ParserTests/RestoreParserTests.cs b/test/dotnet.Tests/ParserTests/RestoreParserTests.cs index cb3128cc0..48a566b92 100644 --- a/test/dotnet.Tests/ParserTests/RestoreParserTests.cs +++ b/test/dotnet.Tests/ParserTests/RestoreParserTests.cs @@ -26,8 +26,6 @@ namespace Microsoft.DotNet.Tests.ParserTests var result = parser.Parse(@"dotnet restore .\some.csproj --packages c:\.nuget\packages /p:SkipInvalidConfigurations=true"); - output.WriteLine(result.Diagram()); - result["dotnet"]["restore"] .Arguments .Should() @@ -41,8 +39,6 @@ namespace Microsoft.DotNet.Tests.ParserTests var result = parser.Parse(@"dotnet restore --packages c:\.nuget\packages /p:SkipInvalidConfigurations=true"); - output.WriteLine(result.Diagram()); - result["dotnet"]["restore"] .Arguments .Should()