3 instantiations of Reporter
Microsoft.DotNet.Cli.Utils (3)
Reporter.cs (3)
13private static readonly Reporter s_consoleOutReporter = new(AnsiConsole.GetOutput()); 14private static readonly Reporter s_consoleErrReporter = new(AnsiConsole.GetError()); 33public static Reporter NullReporter { get; } = new(console: null);
588 references to Reporter
dotnet (273)
BuildServer\BuildServerProvider.cs (1)
21private readonly IReporter _reporter = reporter ?? Reporter.Error;
BuildServer\VBCSCompilerServer.cs (3)
39Reporter.Verbose.WriteLine($"Shutting down '{s_toolsetPackageName}' compilers."); 42Reporter.Verbose.WriteLine($"Enumerating '{toolsetPackageDirectory}'."); 48Reporter.Verbose.WriteLine($"Found '{vbcsCompilerPath}'.");
CliCompletion.cs (1)
30Reporter.Verbose.WriteLine($"Exception occurred while getting completions: {e}");
CommandFactory\CommandResolution\OutputPathCommandResolver.cs (1)
62Reporter.Verbose.WriteLine(
CommandFactory\CommandResolution\PackagedCommandSpecFactory.cs (3)
32Reporter.Verbose.WriteLine(string.Format( 43Reporter.Verbose.WriteLine(string.Format( 55Reporter.Verbose.WriteLine(string.Format(
CommandFactory\CommandResolution\PackagedCommandSpecFactoryWithCliRuntime.cs (2)
38Reporter.Verbose.WriteLine( 71Reporter.Verbose.WriteLine(
CommandFactory\CommandResolution\ProjectDependenciesCommandResolver.cs (6)
40Reporter.Verbose.WriteLine(string.Format( 50Reporter.Verbose.WriteLine(string.Format( 88Reporter.Verbose.WriteLine(string.Format( 99Reporter.Verbose.WriteLine(string.Format( 110Reporter.Verbose.WriteLine(string.Format( 150Reporter.Verbose.WriteLine(string.Format(
CommandFactory\CommandResolution\ProjectFactory.cs (3)
37Reporter.Verbose.WriteLine(string.Format( 44Reporter.Verbose.WriteLine(string.Format( 60Reporter.Verbose.WriteLine(ex.ToString().Red());
CommandFactory\CommandResolution\ProjectToolsCommandResolver.cs (16)
31Reporter.Verbose.WriteLine(string.Format( 54Reporter.Verbose.WriteLine(string.Format( 75Reporter.Verbose.WriteLine(string.Format( 94Reporter.Verbose.WriteLine(string.Format( 107Reporter.Verbose.WriteLine(string.Format( 113Reporter.Verbose.WriteLine(string.Format( 151Reporter.Verbose.WriteLine(string.Format( 162Reporter.Verbose.WriteLine(string.Format( 178Reporter.Verbose.WriteLine(string.Format( 193Reporter.Verbose.WriteLine(string.Format( 290Reporter.Verbose.WriteLine(string.Format( 326Reporter.Verbose.WriteLine(string.Format( 381Reporter.Verbose.WriteLine(string.Format(CliStrings.MSBuildArgs, 422Reporter.Verbose.WriteLine(string.Format( 435Reporter.Verbose.WriteLine(string.Format( 445Reporter.Verbose.WriteLine(string.Format(
CommandFactory\CommandResolution\PublishedPathCommandResolver.cs (3)
41Reporter.Verbose.WriteLine(string.Format( 51Reporter.Verbose.WriteLine(string.Format( 69Reporter.Verbose.WriteLine(string.Format(
CommandLineInfo.cs (15)
17Reporter.Output.WriteLine(Product.Version); 24Reporter.Output.WriteLine($"{LocalizableStrings.DotNetSdkInfoLabel}"); 25Reporter.Output.WriteLine($" Version: {Product.Version}"); 26Reporter.Output.WriteLine($" Commit: {commitSha}"); 27Reporter.Output.WriteLine($" Workload version: {WorkloadCommandParser.GetWorkloadsVersion()}"); 28Reporter.Output.WriteLine($" MSBuild version: {MSBuildForwardingAppWithoutLogging.MSBuildVersion.ToString()}"); 29Reporter.Output.WriteLine(); 30Reporter.Output.WriteLine($"{LocalizableStrings.DotNetRuntimeInfoLabel}"); 31Reporter.Output.WriteLine($" OS Name: {RuntimeEnvironment.OperatingSystem}"); 32Reporter.Output.WriteLine($" OS Version: {RuntimeEnvironment.OperatingSystemVersion}"); 33Reporter.Output.WriteLine($" OS Platform: {RuntimeEnvironment.OperatingSystemPlatform}"); 34Reporter.Output.WriteLine($" RID: {GetDisplayRid(versionFile)}"); 35Reporter.Output.WriteLine($" Base Path: {AppContext.BaseDirectory}"); 41Reporter.Output.WriteLine(); 42Reporter.Output.WriteLine($"{LocalizableStrings.DotnetWorkloadInfoLabel}");
Commands\BuildServer\Shutdown\BuildServerShutdownCommand.cs (3)
51_reporter = reporter ?? Reporter.Output; 52_errorReporter = reporter ?? Reporter.Error; 149Reporter.Verbose.WriteLine(exception.ToString().Red());
Commands\Clean\FileBasedAppArtifacts\CleanFileBasedAppArtifactsCommand.cs (8)
28Reporter.Verbose.WriteLine($"Would remove folder: {folder.FullName}"); 36Reporter.Verbose.WriteLine($"Removed folder: {folder.FullName}"); 41Reporter.Error.WriteLine(string.Format(CliCommandStrings.CleanFileBasedAppArtifactsErrorRemovingFolder, folder, ex.Message).Red()); 47Reporter.Output.WriteLine( 67Reporter.Error.WriteLine(string.Format(CliCommandStrings.CleanFileBasedAppArtifactsDirectoryNotFound, directory.FullName).Yellow()); 71Reporter.Output.WriteLine(CliCommandStrings.CleanFileBasedAppArtifactsScanning, directory.FullName); 122Reporter.Verbose.WriteLine("Starting automatic cleanup of file-based app artifacts."); 174Reporter.Verbose.WriteLine($"Cannot access artifacts metadata file '{metadataFile?.FullName}': {ex}");
Commands\Help\HelpCommand.cs (4)
36Reporter.Output.WriteLine(CliUsage.HelpText); 42Reporter.Output.WriteLine(Product.LongName + versionString); 97Reporter.Error.WriteLine( 101Reporter.Output.WriteLine(CliUsage.HelpText);
Commands\Hidden\Complete\CompleteCommand.cs (1)
17return RunWithReporter(parseResult, Reporter.Output);
Commands\New\NewCommandParser.cs (1)
120Reporter.Reset();
Commands\New\PostActions\DotnetAddPostActionProcessor.cs (18)
48Reporter.Error.WriteLine(CliCommandStrings.PostAction_AddReference_Error_ActionMisconfigured); 58Reporter.Error.WriteLine(CliCommandStrings.PostAction_AddReference_Error_UnresolvedProjFile); 59Reporter.Error.WriteLine(CliCommandStrings.PostAction_AddReference_Error_ProjFileListHeader); 62Reporter.Error.WriteLine(string.Format("\t{0}", projectFile)); 76Reporter.Error.WriteLine(CliCommandStrings.PostAction_AddReference_Error_UnresolvedProjFile); 118Reporter.Error.WriteLine(CliCommandStrings.PostAction_AddReference_Error_ActionMisconfigured); 124Reporter.Error.WriteLine(CliCommandStrings.PostAction_AddReference_Error_ActionMisconfigured); 144Reporter.Error.WriteLine(string.Format(CliCommandStrings.PostAction_AddReference_Error_FrameworkNotSupported, referenceToAdd)); 149Reporter.Error.WriteLine(string.Format(CliCommandStrings.PostAction_AddReference_Error_UnsupportedRefType, referenceType)); 160Reporter.Output.WriteLine(string.Format(CliCommandStrings.PostAction_AddReference_AddPackageReference, packageName, projectPath)); 164Reporter.Output.WriteLine(string.Format(CliCommandStrings.PostAction_AddReference_AddPackageReference_WithVersion, packageName, version, projectPath)); 169Reporter.Output.WriteLine(CliCommandStrings.PostAction_AddReference_Succeeded); 173Reporter.Error.WriteLine(CliCommandStrings.PostAction_AddReference_Failed); 179Reporter.Error.WriteLine(string.Format(CliCommandStrings.PostAction_AddReference_AddPackageReference_Failed, e.Message)); 188Reporter.Output.WriteLine(string.Format(CliCommandStrings.PostAction_AddReference_AddProjectReference, projectToAdd, projectPath)); 192Reporter.Output.WriteLine(CliCommandStrings.PostAction_AddReference_Succeeded); 196Reporter.Error.WriteLine(CliCommandStrings.PostAction_AddReference_Failed); 202Reporter.Error.WriteLine(string.Format(CliCommandStrings.PostAction_AddReference_AddProjectReference_Failed, e.Message));
Commands\New\PostActions\DotnetRestorePostActionProcessor.cs (6)
28Reporter.Output.WriteLine(CliCommandStrings.PostAction_Restore_Error_NoProjectsToRestore); 36Reporter.Error.WriteLine(string.Format(CliCommandStrings.PostAction_Restore_Error_FailedToDetermineProjectToRestore)); 51Reporter.Output.WriteLine(string.Format(CliCommandStrings.PostAction_Restore_Running, pathToRestore)); 55Reporter.Error.WriteLine(CliCommandStrings.PostAction_Restore_Failed); 59Reporter.Output.WriteLine(CliCommandStrings.PostAction_Restore_Succeeded); 65Reporter.Error.WriteLine(string.Format(CliCommandStrings.PostAction_Restore_RestoreFailed, e.Message));
Commands\New\PostActions\DotnetSlnPostActionProcessor.cs (9)
73Reporter.Error.WriteLine(CliCommandStrings.PostAction_AddProjToSln_Error_NoSolutionFile); 83Reporter.Error.WriteLine(CliCommandStrings.PostAction_AddProjToSln_Error_NoProjectsToAdd); 89Reporter.Error.WriteLine(CliCommandStrings.PostAction_AddProjToSln_Error_NoProjectsToAdd); 98Reporter.Error.WriteLine(CliCommandStrings.PostAction_AddProjToSln_Error_BothInRootAndSolutionFolderSpecified); 104Reporter.Output.WriteLine(string.Format(CliCommandStrings.PostAction_AddProjToSln_InRoot_Running, string.Join(" ", projectFiles), nearestSlnFilesFound[0])); 108Reporter.Output.WriteLine(string.Format(CliCommandStrings.PostAction_AddProjToSln_Running, string.Join(" ", projectFiles), nearestSlnFilesFound[0], solutionFolder)); 120Reporter.Error.WriteLine(CliCommandStrings.PostAction_AddProjToSln_Failed_NoReason); 124Reporter.Output.WriteLine(CliCommandStrings.PostAction_AddProjToSln_Succeeded); 131Reporter.Error.WriteLine(string.Format(CliCommandStrings.PostAction_AddProjToSln_Failed, e.Message));
Commands\Package\Add\PackageAddCommand.cs (2)
222Reporter.Verbose.WriteLine($"Assets file does not exist: {projectAssetsFile}"); 285Reporter.Verbose.WriteLine($"Directory.Packages.props file does not exist: {directoryPackagesPropsPath}");
Commands\Package\Remove\PackageRemoveCommand.cs (1)
88Reporter.Output.WriteLine(CliCommandStrings.DirectivesRemoved, "#:package", count, packageId, fullPath);
Commands\Project\Convert\ProjectConvertCommand.cs (5)
46Reporter.Output.WriteLine(CliCommandStrings.ProjectConvertWouldCopyFile, file, targetFile); 47Reporter.Output.WriteLine(CliCommandStrings.ProjectConvertWouldConvertFile, targetFile); 58Reporter.Output.WriteLine(CliCommandStrings.ProjectConvertWouldCreateFile, projectFile); 91Reporter.Output.WriteLine(CliCommandStrings.ProjectConvertWouldCreateDirectory, path); 104Reporter.Output.WriteLine(CliCommandStrings.ProjectConvertWouldCopyFile, source, target);
Commands\Reference\Add\ReferenceAddCommand.cs (3)
45Reporter.Error.Write(GetProjectNotCompatibleWithFrameworksDisplayString( 58Reporter.Error.WriteLine(string.Format( 69Reporter.Error.Write(GetProjectNotCompatibleWithFrameworksDisplayString(@ref, [frameworkString]));
Commands\Reference\List\ReferenceListCommand.cs (4)
37Reporter.Output.WriteLine(string.Format(CliStrings.NoReferencesFound, CliStrings.P2P, _fileOrDirectory)); 42Reporter.Output.WriteLine($"{CliStrings.ProjectReferenceOneOrMore}"); 43Reporter.Output.WriteLine(new string('-', CliStrings.ProjectReferenceOneOrMore.Length)); 46Reporter.Output.WriteLine(item.EvaluatedInclude);
Commands\Run\CSharpCompilerCommand.cs (7)
114Reporter.Verbose.WriteLine($"Copying '{objFile}' to '{BuildResultFile}'."); 135Reporter.Verbose.WriteLine("Compiler server processed compilation."); 136Reporter.Output.Write(completed.Output); 141Reporter.Error.WriteLine("Error: Compiler server reports a different hash version than the SDK.".Red()); 146Reporter.Output.WriteLine("Warning: Could not launch the compiler server.".Yellow()); 151Reporter.Error.WriteLine($"Warning: Compiler server returned unexpected response: {response.GetType().Name}".Yellow()); 341Reporter.Verbose.WriteLine($"Generating CSC auxiliary file because it does not exist: {file}");
Commands\Run\RunCommand.cs (13)
132Reporter.Output.WriteLine(CliCommandStrings.RunCommandBuilding); 226Reporter.Output.WriteLine(string.Format(CliCommandStrings.UsingLaunchSettingsFromMessage, launchSettingsPath)); 236Reporter.Error.WriteLine(string.Format(CliCommandStrings.RunCommandExceptionCouldNotApplyLaunchSettings, profileName, applyResult.FailureReason).Bold().Red()); 245Reporter.Error.WriteLine(string.Format(CliCommandStrings.RunCommandExceptionCouldNotApplyLaunchSettings, profileName).Bold().Red()); 246Reporter.Error.WriteLine(ex.Message.Bold().Red()); 281Reporter.Output.WriteLine(string.Format(CliCommandStrings.RunCommandWarningRunJsonNotUsed, runJsonPath, launchSettingsPath).Yellow()); 294Reporter.Error.WriteLine(string.Format(CliCommandStrings.RunCommandExceptionCouldNotLocateALaunchSettingsFile, launchProfile, $""" 330Reporter.Error.WriteLine(); 390Reporter.Verbose.WriteLine("Getting target command: from cache."); 399Reporter.Verbose.WriteLine("Getting target command: for csc-built program."); 403Reporter.Verbose.WriteLine("Getting target command: evaluating project."); 611Reporter.Output.WriteLine(CliCommandStrings.RunCommandProjectAbbreviationDeprecated.Yellow()); 785Reporter.Verbose.WriteLine($"Failed to send run telemetry: {ex}");
Commands\Run\VirtualProjectBuildingCommand.cs (36)
233Reporter.Output.WriteLine(CliCommandStrings.NoBinaryLogBecauseUpToDate.Yellow()); 247Reporter.Output.WriteLine(CliCommandStrings.NoBinaryLogBecauseRunningJustCsc.Yellow()); 381Reporter.Error.WriteLine(CommandLoggingContext.IsVerbose ? 451Reporter.Verbose.WriteLine($"Not saving CSC arguments because there is an opt-out via MSBuild property {FileBasedProgramCanSkipMSBuild}."); 459Reporter.Verbose.WriteLine("Not saving CSC arguments because there is a project directive."); 474Reporter.Verbose.WriteLine($"Reusing previous CSC arguments ({cache.CurrentEntry.CscArguments.Length}) because none were found in the {Constants.CoreCompile} target."); 484Reporter.Verbose.WriteLine($"Found CSC arguments ({cache.CurrentEntry.CscArguments.Length}) and build result path: {cache.CurrentEntry.BuildResultFile}"); 489Reporter.Verbose.WriteLine($"No CSC arguments found in targets: {string.Join(", ", result.ResultsByTarget.Keys)}"); 671Reporter.Verbose.WriteLine("CSC auxiliary files can NOT be reused due to the same reason build is needed."); 677Reporter.Verbose.WriteLine("CSC auxiliary files can NOT be reused because previous build level was not CSC " + 682Reporter.Verbose.WriteLine("CSC auxiliary files can be reused."); 753Reporter.Verbose.WriteLine("Building because cache file does not exist: " + successCacheFile.FullName); 760Reporter.Verbose.WriteLine("Building because start cache file does not exist: " + startCacheFile.FullName); 768Reporter.Verbose.WriteLine("Building because start cache file is newer than success cache file (previous build likely failed): " + startCacheFile.FullName); 778Reporter.Verbose.WriteLine("Building because previous cache entry could not be deserialized: " + successCacheFile.FullName); 790Reporter.Verbose.WriteLine($""" 799Reporter.Verbose.WriteLine($""" 809Reporter.Verbose.WriteLine($""" 820Reporter.Verbose.WriteLine($""" 832Reporter.Verbose.WriteLine("Building because entry point file is missing: " + entryPointFile.FullName); 840Reporter.Verbose.WriteLine("Compiling because entry point file is modified: " + entryPointFile.FullName); 850Reporter.Verbose.WriteLine("Building because implicit build file is missing or modified: " + implicitBuildFileInfo.FullName); 860Reporter.Verbose.WriteLine("Building because new implicit build file is present: " + implicitBuildFilePath); 877Reporter.Verbose.WriteLine($"Failed to deserialize cache entry ({path}): {e.GetType().FullName}: {e.Message}"); 900Reporter.Verbose.WriteLine("No need to build, the output is up to date."); 909Reporter.Verbose.WriteLine("No CSC arguments from previous run."); 913Reporter.Verbose.WriteLine("We have CSC arguments but not run properties. That's unexpected."); 917Reporter.Verbose.WriteLine("We have CSC arguments but not build result file. That's unexpected."); 921Reporter.Verbose.WriteLine("Cannot use CSC arguments from previous run because directives changed."); 925Reporter.Verbose.WriteLine("We have CSC arguments from previous run. Skipping MSBuild and using CSC only."); 941Reporter.Verbose.WriteLine("Using MSBuild because there are directives in the source file."); 949Reporter.Verbose.WriteLine($"Using MSBuild because there are global properties, for example '{exampleKey}={exampleValue}'."); 956Reporter.Verbose.WriteLine($"Using MSBuild because there are implicit build files, for example '{exampleMSBuildFile}'."); 964Reporter.Verbose.WriteLine($"Using MSBuild because NuGet package file does not exist: {filePath}"); 969Reporter.Verbose.WriteLine("Skipping MSBuild and using CSC only."); 1008Reporter.Verbose.WriteLine($"Cannot touch folder '{directory}': {ex}");
Commands\Sdk\Check\SdkCheckCommand.cs (1)
33_reporter = reporter ?? Reporter.Output;
Commands\Solution\Add\SolutionAddCommand.cs (4)
156Reporter.Error.WriteLine(string.Format(CliStrings.InvalidProjectWithExceptionMessage, fullProjectPath, ex.Message)); 207Reporter.Error.WriteLine(CliStrings.UnsupportedProjectType, fullProjectPath); 214Reporter.Output.WriteLine(CliStrings.SolutionAlreadyContainsProject, _solutionFileFullPath, solutionRelativeProjectPath); 244Reporter.Output.WriteLine(CliStrings.ProjectAddedToTheSolution, solutionRelativeProjectPath);
Commands\Solution\List\SolutionListCommand.cs (4)
48Reporter.Output.WriteLine(CliStrings.NoProjectsFound); 55Reporter.Output.WriteLine(header); 56Reporter.Output.WriteLine(new string('-', header.Length)); 59Reporter.Output.WriteLine(slnProject);
Commands\Solution\Migrate\SolutionMigrateCommand.cs (1)
18private readonly IReporter _reporter = reporter ?? Reporter.Output;
Commands\Solution\Remove\SolutionRemoveCommand.cs (2)
85Reporter.Output.WriteLine(CliStrings.ProjectNotFoundInTheSolution, projectPath); 91Reporter.Output.WriteLine(CliStrings.ProjectRemovedFromTheSolution, projectPath);
Commands\Test\MTP\MSBuildHandler.cs (3)
52Reporter.Error.WriteLine(string.Format(CliCommandStrings.CmdMSBuildProjectsPropertiesErrorDescription, msBuildExitCode)); 83Reporter.Error.WriteLine(message); 112Reporter.Error.WriteLine(
Commands\Test\MTP\SolutionAndProjectUtility.cs (3)
383Reporter.Output.WriteLine(string.Format(CliCommandStrings.RunCommandWarningRunJsonNotUsed, runJsonPath, launchSettingsPath).Yellow()); 398Reporter.Output.WriteLine(string.Format(CliCommandStrings.UsingLaunchSettingsFromMessage, launchSettingsPath)); 404Reporter.Error.WriteLine(string.Format(CliCommandStrings.RunCommandExceptionCouldNotApplyLaunchSettings, profileName, result.FailureReason).Bold().Red());
Commands\Test\MTP\TestApplication.cs (1)
383Reporter.Error.WriteLine(messageBuilder.ToString());
Commands\Test\MTP\TestApplicationActionQueue.cs (1)
73Reporter.Error.WriteLine(string.Format(CliCommandStrings.ErrorRunningTestModule, module.RunProperties?.Command, module.RunProperties?.Arguments, exAsString));
Commands\Test\MTP\ValidationUtility.cs (3)
120Reporter.Error.WriteLine(string.Format(CliCommandStrings.CmdInvalidSolutionFileExtensionErrorDescription, path)); 138Reporter.Error.WriteLine(string.Format(CliCommandStrings.CmdInvalidProjectFileExtensionErrorDescription, path)); 149Reporter.Error.WriteLine(string.Format(CliCommandStrings.CmdNonExistentFileErrorDescription, Path.GetFullPath(filePath)));
Commands\Test\VSTest\TestCommand.cs (1)
133Reporter.Output.WriteLine(string.Format(CliCommandStrings.IgnoredArgumentsMessage, string.Join(" ", ignoredArgs)).Yellow());
Commands\Tool\Execute\ToolExecuteCommand.cs (3)
74Reporter.Error.WriteLine(restoreResult.Message.Red()); 103Reporter.Error.WriteLine(CliCommandStrings.ToolDownloadCanceled.Red().Bold()); 108Reporter.Error.WriteLine(CliCommandStrings.ToolDownloadNeedsConfirmation.Red().Bold());
Commands\Tool\Install\ProjectRestorer.cs (2)
16private readonly IReporter _reporter = reporter ?? Reporter.Output; 17private readonly IReporter _errorReporter = reporter ?? Reporter.Error;
Commands\Tool\Install\ToolInstallGlobalOrToolPathCommand.cs (1)
106_reporter = reporter ?? Reporter.Output;
Commands\Tool\Install\ToolInstallLocalCommand.cs (1)
55_reporter = reporter ?? Reporter.Output;
Commands\Tool\List\ToolListGlobalOrToolPathCommand.cs (2)
22private readonly IReporter _reporter = reporter ?? Reporter.Output; 23private readonly IReporter _errorReporter = reporter ?? Reporter.Error;
Commands\Tool\List\ToolListLocalCommand.cs (1)
26_reporter = reporter ?? Reporter.Output;
Commands\Tool\Restore\ToolRestoreCommand.cs (2)
61_reporter = reporter ?? Reporter.Output; 62_errorReporter = reporter ?? Reporter.Error;
Commands\Tool\Search\ToolSearchCommand.cs (2)
18private readonly SearchResultPrinter _searchResultPrinter = new SearchResultPrinter(Reporter.Output); 25Reporter.Output.WriteLine(CliCommandStrings.NeedNuGetInConfig);
Commands\Tool\Uninstall\ToolUninstallGlobalOrToolPathCommand.cs (2)
26private readonly IReporter _reporter = reporter ?? Reporter.Output; 27private readonly IReporter _errorReporter = reporter ?? Reporter.Error;
Commands\Tool\Uninstall\ToolUninstallLocalCommand.cs (1)
35_reporter = reporter ?? Reporter.Output;
Commands\Tool\Update\ToolUpdateLocalCommand.cs (1)
34_reporter = reporter ?? Reporter.Output;
Commands\Workload\Clean\WorkloadCleanCommand.cs (1)
117Utils.Reporter.Verbose.WriteLine(ex.Message);
Commands\Workload\Install\FileBasedInstaller.cs (1)
401Reporter.Verbose);
Commands\Workload\Install\WorkloadGarbageCollector.cs (1)
35private readonly IReporter _verboseReporter = verboseReporter ?? Reporter.NullReporter;
Commands\Workload\Search\WorkloadSearchVersionsCommand.cs (4)
93Utils.Reporter.Error.WriteLine(string.Format(CliCommandStrings.NoWorkloadVersionsFound, new SdkFeatureBand(_sdkVersion))); 161installer ??= GenerateInstaller(Utils.Reporter.NullReporter, featureBand, resolver, VerbosityOptions.d, interactive: false); 176installer ??= GenerateInstaller(Utils.Reporter.NullReporter, featureBand, resolver, VerbosityOptions.d, interactive: false); 185Utils.Reporter.Error.WriteLine(string.Format(CliCommandStrings.NoWorkloadVersionsFound, featureBand));
Commands\Workload\WorkloadCommandBase.cs (1)
103Reporter = reporter ?? Utils.Reporter.Output;
Commands\Workload\WorkloadCommandParser.cs (4)
65reporter ??= Reporter.Output; 182Reporter.Output.WriteLine(string.Empty); 193Reporter.Output.WriteLine(GetWorkloadsVersion()); 194Reporter.Output.WriteLine(string.Empty);
Extensions\ParseResultExtensions.cs (1)
113Reporter.Error.WriteLine(CliStrings.RequiredCommandNotPassed.Red());
MsbuildProject.cs (4)
124Reporter.Output.WriteLine(string.Format( 133Reporter.Output.WriteLine(string.Format(CliStrings.ReferenceAddedToTheProject, @ref)); 255Reporter.Output.WriteLine(string.Format(CliStrings.ProjectReferenceRemoved, r)); 261Reporter.Output.WriteLine(string.Format(
NugetPackageDownloader\NuGetConsoleLogger.cs (7)
57Reporter.Verbose.WriteLine($"[NuGet Manager] [DEBUG] {data}"); 62Reporter.Error.WriteLine($"[NuGet Manager] [Error] {data}"); 67Reporter.Output.WriteLine($"[NuGet Manager] [Info] {data}"); 72Reporter.Output.WriteLine($"[NuGet Manager] [Info Summary] {data}"); 77Reporter.Output.WriteLine($"[NuGet Manager] {data}"); 82Reporter.Verbose.WriteLine($"[NuGet Manager] [Verbose] {data}"); 87Reporter.Error.WriteLine($"[NuGet Manager] [Warning] {data}");
NugetPackageDownloader\NuGetPackageDownloader.cs (1)
67_reporter = reporter ?? Reporter.Output;
Parser.cs (5)
269Reporter.Error.WriteLine(CommandLoggingContext.IsVerbose ? 275Reporter.Error.WriteLine(CommandLoggingContext.IsVerbose ? 282Reporter.Error.WriteLine(CommandLoggingContext.IsVerbose ? 288Reporter.Error.Write("Unhandled exception: ".Red().Bold()); 289Reporter.Error.WriteLine(CommandLoggingContext.IsVerbose ?
Program.cs (7)
85Reporter.Error.WriteLine(CommandLoggingContext.IsVerbose 101Reporter.Error.WriteLine(e.ToString().Red().Bold()); 163Reporter.Reset(); 282Reporter.Error.WriteLine(e.Message.Red()); 283Reporter.Output.WriteLine(e.InstructionMessage); 377Reporter.Verbose.WriteLine( 398var reporter = Reporter.Error;
ReleasePropertyProjectLocator.cs (1)
258Reporter.Error.WriteLine(e.Message);
ShellShim\EnvironmentPathFactory.cs (5)
35Reporter.Output); 42Reporter.Output, 50reporter: Reporter.Output, 67reporter: Reporter.Output, 78reporter: Reporter.Output);
Telemetry\PersistenceChannel\PersistenceChannelDebugLog.cs (1)
25Reporter.Output.WriteLine(message);
ToolPackage\ToolPackageDownloader.cs (3)
93Reporter.Output.WriteLine($"Extracting package {packageId}@{packageVersion} to {packagePath}"); 147Reporter.Output.WriteLine($"Locating package {packageId}@{version} in package store {packagesRootPath.Value}"); 148Reporter.Output.WriteLine($"The package has {string.Join(',', package.Nuspec.GetPackageTypes().Select(p => $"{p.Name},{p.Version}"))} package types");
ToolPackage\ToolPackageDownloaderBase.cs (7)
207Reporter.Output.WriteLine($"Configuring package {packageId}@{packageVersion} for runtime roll-forward"); 342Reporter.Output.WriteLine($"Resolving RID-specific package for {packageId} {packageVersion}"); 343Reporter.Output.WriteLine($"Target RID: {RuntimeInformation.RuntimeIdentifier}"); 344Reporter.Output.WriteLine($"Available RID-specific packages: {string.Join(", ", toolConfiguration.RidSpecificPackages.Keys)}"); 357Reporter.Output.WriteLine($"Best matching RID: {bestRuntimeIdentifier}"); 358Reporter.Output.WriteLine($"Resolved package: {resolvedPackage}"); 369Reporter.Output.WriteLine($"No RID-specific package declared for {packageId} {packageVersion}.");
TransactionalAction.cs (2)
89Reporter.Verbose.WriteLine(string.Format("TransactionAbortedException Message: {0}", ex.Message)); 90Reporter.Verbose.WriteLine(
dotnet.Tests (2)
CommandTests\Workload\Update\GivenDotnetWorkloadUpdate.cs (2)
96Reporter.Output, 322var updateCommand = new WorkloadUpdateCommand(Parser.Parse("dotnet workload update"), Reporter.Output, resolverFactory, workloadInstaller, nugetPackageDownloader, workloadManifestUpdater, shouldUseWorkloadSetsFromGlobalJson: globalJsonValue);
Microsoft.DotNet.Cli.Utils (15)
BuiltInCommand.cs (2)
56Reporter.Reset(); 84Reporter.Reset();
Command.cs (7)
32Reporter.Verbose.WriteLine(string.Format( 48Reporter.Verbose.WriteLine($"> {Command.FormatProcessInfo(_process.StartInfo)}".White()); 57Reporter.Verbose.WriteLine(string.Format( 81Reporter.Verbose.WriteLine(message.Green()); 85Reporter.Verbose.WriteLine(message.Red().Bold()); 140_stdOut?.ForwardTo(writeLine: Reporter.Output.WriteLine); 160_stdErr?.ForwardTo(writeLine: Reporter.Error.WriteLine);
Extensions\ExceptionExtensions.cs (1)
17Reporter.Verbose.WriteLine($"Warning: Ignoring exception: {e.ToString().Yellow()}");
Reporter.cs (5)
13private static readonly Reporter s_consoleOutReporter = new(AnsiConsole.GetOutput()); 14private static readonly Reporter s_consoleErrReporter = new(AnsiConsole.GetError()); 33public static Reporter NullReporter { get; } = new(console: null); 34public static Reporter ConsoleOutReporter => s_consoleOutReporter; 35public static Reporter ConsoleErrReporter => s_consoleErrReporter;
Microsoft.NET.TestFramework (1)
TestContext.cs (1)
137Reporter.Reset();
Microsoft.TemplateEngine.Cli (295)
Commands\AliasAssignmentCoordinator.cs (1)
161Reporter.Verbose.WriteLine(string.Format(LocalizableStrings.AliasAssignmentCoordinator_Error_ShortAlias, parameter.Name, shortName, qualifiedShortName));
Commands\BaseCommand.cs (19)
96Reporter.Output.WriteLine(LocalizableStrings.Commands_TemplateShortNameCommandConflict_Info, usedCommandAlias); 97Reporter.Output.WriteCommand(Example.For<InstantiateCommand>(args.ParseResult).WithArgument(InstantiateCommand.ShortNameArgument, usedCommandAlias)); 98Reporter.Output.WriteLine(); 111Reporter.Output.WriteLine(string.Format( 116Reporter.Output.WriteLine(LocalizableStrings.Commands_Warning_DeprecatedCommand_Info.Yellow()); 117Reporter.Output.WriteCommand(Example.For<TNew>(parseResult).WithHelpOption().ToString().Yellow()); 118Reporter.Output.WriteLine(); 169Reporter.Output.WriteLine("Attach to the process and press any key"); 199Reporter.Output.WriteLine(LocalizableStrings.CurrentConfiguration); 200Reporter.Output.WriteLine(" "); 210Reporter.Output.WriteLine(mountPointsFormatter.Layout()); 211Reporter.Output.WriteLine(); 221Reporter.Output.WriteLine(generatorsFormatter.Layout()); 222Reporter.Output.WriteLine(); 257Reporter.Error.WriteLine(ex.Message.Bold().Red()); 270Reporter.Error.WriteLine(ex.Message.Bold().Red()); 275Reporter.Error.WriteLine(ex.StackTrace.Bold().Red()); 282Reporter.Error.WriteLine(); 283Reporter.Error.WriteLine(LocalizableStrings.BaseCommand_ExitCodeHelp, (int)returnCode);
Commands\CliPathInfo.cs (1)
47Reporter.Verbose.WriteLine($"Global Settings Location: {definedSettingsLocation}");
Commands\create\InstantiateCommand.cs (7)
221HandleNoMatchingTemplateGroup(instantiateArgs, allTemplateGroups, Reporter.Error); 226return HandleAmbiguousTemplateGroup(environmentSettings, templatePackageManager, selectedTemplateGroups, Reporter.Error, cancellationToken); 293Reporter.Error, 297return HandleNoTemplateFoundResult(args, environmentSettings, templatePackageManager, templateGroup, Reporter.Error); 313Reporter.Error); 322Reporter.Error); 449Reporter.Error.WriteLine(LocalizableStrings.GenericWarning, e.Message);
Commands\create\InstantiateCommand.Help.cs (4)
44HandleNoMatchingTemplateGroup(instantiateCommandArgs, allTemplateGroups, Reporter.Output); 49HandleAmbiguousTemplateGroup(environmentSettings, templatePackageManager, selectedTemplateGroups, Reporter.Output); 64HandleNoTemplateFoundResult(instantiateCommandArgs, environmentSettings, templatePackageManager, templateGroup, Reporter.Output); 71Reporter.Output,
Commands\create\InstantiateCommand.NoMatchHandling.cs (3)
196Reporter.Error.WriteLine(string.Format(LocalizableStrings.Generic_Info_NoMatchingTemplates, baseInputParameters).Bold().Red()); 207Reporter.Error.WriteLine(string.Format(LocalizableStrings.TemplateOptions_Error_AllowedValuesForOptionList, token.Value, allowedValues)); 211Reporter.Error.WriteLine();
Commands\create\InstantiateCommand.TabCompletion.cs (1)
92Reporter.Error.WriteLine(LocalizableStrings.GenericWarning, e.Message);
Commands\create\TemplateCommand.cs (5)
154TemplatePackageDisplay templatePackageDisplay = new(Reporter.Output, Reporter.Error); 181Reporter.Output.WriteLine(); 223var reporter = templateArgs.IsForceFlagSpecified ? Reporter.Output : Reporter.Error;
NuGet\CliNuGetLogger.cs (7)
43Reporter.Verbose.WriteLine($"[NuGet Manager] [DEBUG] {data}"); 48Reporter.Error.WriteLine($"[NuGet Manager] [Error] {data}"); 53Reporter.Output.WriteLine($"[NuGet Manager] [Info] {data}"); 58Reporter.Output.WriteLine($"[NuGet Manager] [Info Summary] {data}"); 63Reporter.Output.WriteLine($"[NuGet Manager] {data}"); 68Reporter.Verbose.WriteLine($"[NuGet Manager] [Verbose] {data}"); 73Reporter.Error.WriteLine($"[NuGet Manager] [Warning] {data}");
PostActionDispatcher.cs (19)
88Reporter.Output.WriteLine(); 89Reporter.Output.WriteLine(LocalizableStrings.ProcessingPostActions); 101Reporter.Output.WriteLine(LocalizableStrings.ActionWouldHaveBeenTakenAutomatically); 104Reporter.Output.WriteLine(action.Description.Indent()); 114Reporter.Error.WriteLine(LocalizableStrings.PostActionDispatcher_Error_NotSupported, action.ActionId); 117Reporter.Error.WriteLine(LocalizableStrings.PostActionDescription, action.Description); 127Reporter.Error.WriteLine(LocalizableStrings.PostActionDispatcher_Error_RunScriptNotAllowed); 130Reporter.Error.WriteLine(LocalizableStrings.PostActionDescription, action.Description); 170Reporter.Output.WriteLine(); 180Reporter.Output.WriteLine(LocalizableStrings.PostActionPromptHeader); 183Reporter.Output.WriteLine(LocalizableStrings.PostActionDescription, action.Description); 189Reporter.Output.WriteLine(string.Format(LocalizableStrings.PostActionCommand, $"{executable} {commandArgs}").Bold().Red()); 191Reporter.Output.WriteLine(LocalizableStrings.PostActionPromptRequest, YesAnswer, NoAnswer); 206Reporter.Output.WriteLine(LocalizableStrings.PostActionInvalidInputRePrompt, input, YesAnswer, NoAnswer); 227Reporter.Error.WriteLine(LocalizableStrings.PostActionFailedInstructionHeader); 233Reporter.Error.WriteLine(LocalizableStrings.PostActionFailedInstructionHeader); 234Reporter.Verbose.WriteLine(LocalizableStrings.Generic_Details, e.ToString()); 249IReporter stream = useErrorOutput ? Reporter.Error : Reporter.Output;
PostActionProcessors\AddJsonPropertyPostActionProcessor.cs (11)
86Reporter.Error.WriteLine(string.Format(LocalizableStrings.PostAction_ModifyJson_Error_ArgumentNotConfigured, JsonFileNameArgument)); 96Reporter.Error.WriteLine(string.Format(LocalizableStrings.PostAction_ModifyJson_Error_ArgumentNotBoolean, AllowFileCreationArgument)); 102Reporter.Error.WriteLine(LocalizableStrings.PostAction_ModifyJson_Error_NoJsonFile); 108Reporter.Error.WriteLine(string.Format(LocalizableStrings.PostAction_ModifyJson_Error_ArgumentNotBoolean, DetectRepoRootForFileCreation)); 119Reporter.Error.WriteLine(string.Format(LocalizableStrings.PostAction_ModifyJson_Error_MultipleJsonFiles, jsonFileName)); 146Reporter.Output.WriteLine(string.Format(LocalizableStrings.PostAction_ModifyJson_Succeeded, jsonFileName)); 162Reporter.Error.WriteLine(string.Format(LocalizableStrings.PostAction_ModifyJson_Error_ArgumentNotBoolean, AllowPathCreationArgument)); 170Reporter.Error.WriteLine(string.Format(LocalizableStrings.PostAction_ModifyJson_Error_ParentPropertyPathInvalid, propertyPath)); 232Reporter.Verbose.WriteLine(string.Format(LocalizableStrings.PostAction_ModifyJson_Verbose_AttemptingToFindJsonFile, matchPattern, directory)); 278Reporter.Error.WriteLine(string.Format(LocalizableStrings.PostAction_ModifyJson_Error_ArgumentNotConfigured, NewJsonPropertyNameArgument)); 284Reporter.Error.WriteLine(string.Format(LocalizableStrings.PostAction_ModifyJson_Error_ArgumentNotConfigured, NewJsonPropertyValueArgument));
PostActionProcessors\ChmodPostActionProcessor.cs (5)
55Reporter.Error.WriteLine(LocalizableStrings.UnableToSetPermissions, entry.Key, file); 56Reporter.Verbose.WriteLine("Unable to start sub-process."); 65Reporter.Error.WriteLine(LocalizableStrings.UnableToSetPermissions, entry.Key, file); 71Reporter.Error.WriteLine(LocalizableStrings.UnableToSetPermissions, entry.Key, file); 72Reporter.Verbose.WriteLine(LocalizableStrings.Generic_Details, ex.ToString());
PostActionProcessors\InstructionDisplayPostActionProcessor.cs (3)
18Reporter.Output.WriteLine(LocalizableStrings.PostActionDescription, actionConfig.Description); 19Reporter.Output.WriteLine(LocalizableStrings.PostActionInstructions, actionConfig.ManualInstructions); 24Reporter.Output.WriteLine(string.Format(LocalizableStrings.PostActionCommand, $"{executable} {commandArgs}").Bold().Red());
PostActionProcessors\ProcessStartPostActionProcessor.cs (12)
21Reporter.Error.WriteLine(LocalizableStrings.PostAction_ProcessStartProcessor_Error_ConfigMissingExecutable); 50Reporter.Output.WriteLine(LocalizableStrings.RunningCommand, command); 66Reporter.Error.WriteLine(LocalizableStrings.CommandFailed); 67Reporter.Verbose.WriteLine("Unable to start sub-process."); 75Reporter.Error.WriteLine(LocalizableStrings.CommandFailed); 76Reporter.Error.WriteCommandOutput(commandResult); 77Reporter.Error.WriteLine(string.Empty); 82Reporter.Output.WriteLine(LocalizableStrings.CommandSucceeded); 88Reporter.Error.WriteLine(LocalizableStrings.CommandFailed); 89Reporter.Error.WriteLine(ex.Message); 90Reporter.Error.WriteLine(string.Empty); 91Reporter.Verbose.WriteLine(LocalizableStrings.Generic_Details, ex.ToString());
TemplateInvoker.cs (35)
67Reporter.Error.WriteLine(cx.Message.Bold().Red()); 70Reporter.Error.WriteLine(cx.InnerException.Message.Bold().Red()); 78Reporter.Error.WriteLine(ex.Message.Bold().Red()); 137Reporter.Error.WriteLine(string.Format(LocalizableStrings.InvalidNameParameter, printableChars, nonPrintableChars).Bold().Red()); 179Reporter.Error.WriteLine(cx.Message.Bold().Red()); 182Reporter.Error.WriteLine(cx.InnerException.Message.Bold().Red()); 189Reporter.Error.WriteLine(tae.Message.Bold().Red()); 200Reporter.Output.WriteLine(LocalizableStrings.CreateSuccessful, resultTemplateName); 204Reporter.Output.WriteLine(LocalizableStrings.FileActionsWouldHaveBeenTaken); 209Reporter.Output.WriteLine($" {GetChangeString(change.ChangeKind)}: {AdjustReportedPath(change.TargetRelativePath)}"); 216Reporter.Output.WriteLine(LocalizableStrings.ThirdPartyNotices, templateArgs.Template.ThirdPartyNotices); 222Reporter.Error.WriteLine(string.Format(LocalizableStrings.CreateFailed, resultTemplateName, instantiateResult.ErrorMessage).Bold().Red()); 233Reporter.Error.WriteLine(string.Format(LocalizableStrings.MissingRequiredParameter, fixedMessage, resultTemplateName).Bold().Red()); 237Reporter.Error.WriteLine(LocalizableStrings.TemplateCreator_Error_TemplateNotFound.Bold().Red()); 238Reporter.Error.WriteLine(); 239Reporter.Output.WriteLine(LocalizableStrings.TemplateCreator_Hint_RebuildCache); 240Reporter.Output.WriteCommand(Example.For<NewCommand>(templateArgs.ParseResult).WithOption(NewCommand.DebugRebuildCacheOption)); 241Reporter.Output.WriteLine(); 255Reporter.Output.WriteLine(LocalizableStrings.TemplateCreator_Hint_Uninstall); 256Reporter.Output.WriteCommand(Example.For<UninstallCommand>(templateArgs.ParseResult).WithArgument(BaseUninstallCommand.NameArgument, templatePackage.DisplayName)); 257Reporter.Output.WriteLine(); 258Reporter.Output.WriteLine(LocalizableStrings.TemplateCreator_Hint_Install); 259Reporter.Output.WriteCommand(Example.For<InstallCommand>(templateArgs.ParseResult).WithArgument(BaseInstallCommand.NameArgument, templatePackage.DisplayName)); 260Reporter.Output.WriteLine(); 266Reporter.Error.WriteLine($"{LocalizableStrings.InvalidCommandOptions}: {instantiateResult.ErrorMessage}".Bold().Red()); 267Reporter.Error.WriteLine(LocalizableStrings.RunHelpForInformationAboutAcceptedParameters); 268Reporter.Error.WriteCommand( 275Reporter.Error.WriteLine(LocalizableStrings.DestructiveChangesNotification.Bold().Red()); 284Reporter.Error.WriteLine(($" {GetChangeString(change.ChangeKind)}".PadRight(padLen) + AdjustReportedPath(change.TargetRelativePath)).Bold().Red()); 286Reporter.Error.WriteLine(); 288Reporter.Error.WriteLine( 292Reporter.Error.WriteCommand(Example.FromExistingTokens(templateArgs.ParseResult).WithOption(SharedOptions.ForceOption)); 297Reporter.Error.WriteLine(instantiateResult.ErrorMessage.Bold().Red()); 301Reporter.Error.WriteLine(LocalizableStrings.OperationCancelled.Bold().Red()); 304Reporter.Error.WriteLine(string.Format(LocalizableStrings.UnexpectedResult, Enum.GetName(typeof(CreationResultStatus), instantiateResult.Status), instantiateResult.ErrorMessage).Bold().Red());
TemplateListCoordinator.cs (30)
53Reporter.Output.WriteLine(LocalizableStrings.TemplatesFoundMatchingInputParameters, GetInputParametersString(args)); 54Reporter.Output.WriteLine(); 62reporter: Reporter.Output, 72Reporter.Output.WriteLine(LocalizableStrings.NoTemplatesFound); 73Reporter.Output.WriteLine(); 75Reporter.Output.WriteLine(LocalizableStrings.Generic_CommandHints_Search); 76Reporter.Output.WriteCommand( 81Reporter.Output.WriteLine(); 87Reporter.Error.WriteLine( 96Reporter.Error.WriteLine( 108Reporter.Error.WriteLine( 116Reporter.Error.WriteLine(); 118Reporter.Error.WriteLine(LocalizableStrings.Generic_CommandHints_Search); 121Reporter.Error.WriteCommand( 129Reporter.Error.WriteCommand( 135Reporter.Error.WriteLine(); 152Reporter.Output.WriteLine(LocalizableStrings.TemplateInformationCoordinator_DotnetNew_Description, Example.For<NewCommand>(args.ParseResult)); 154Reporter.Output.WriteLine(); 156Reporter.Output.WriteLine(LocalizableStrings.TemplateInformationCoordinator_DotnetNew_TemplatesHeader, Example.For<NewCommand>(args.ParseResult)); 161reporter: Reporter.Output); 163Reporter.Output.WriteLine(LocalizableStrings.TemplateInformationCoordinator_DotnetNew_ExampleHeader); 164Reporter.Output.WriteCommand( 169Reporter.Output.WriteLine(); 171Reporter.Output.WriteLine(LocalizableStrings.TemplateInformationCoordinator_DotnetNew_DisplayOptionsHint); 172Reporter.Output.WriteCommand( 178Reporter.Output.WriteLine(LocalizableStrings.TemplateInformationCoordinator_DotnetNew_ListTemplatesHint); 180Reporter.Output.WriteCommand( 185Reporter.Output.WriteLine(LocalizableStrings.TemplateInformationCoordinator_DotnetNew_SearchTemplatesHint); 186Reporter.Output.WriteCommand( 192Reporter.Output.WriteLine();
TemplatePackageCoordinator.cs (87)
47_templatePackageDisplay = new TemplatePackageDisplay(Reporter.Output, Reporter.Error); 73Reporter.Error.WriteLine(LocalizableStrings.TemplatePackageCoordinator_Error_PackageForTemplateNotFound, args.Template.Identity); 99Reporter.Error.WriteLine(LocalizableStrings.TemplatePackageCoordinator_Error_PackageForTemplateNotFound, template.Identity); 149Reporter.Output.WriteLine(LocalizableStrings.TemplatePackageCoordinator_Update_Info_UpdateAvailable, displayString); 151Reporter.Output.WriteLine(LocalizableStrings.TemplatePackageCoordinator_Update_Info_UpdateSingleCommandHeader); 152Reporter.Output.WriteCommand( 157Reporter.Output.WriteLine(); 163Reporter.Error.WriteLine(); 169Reporter.Output.WriteLine(LocalizableStrings.TemplatePackageCoordinator_BuiltInCheck_Info_BuiltInPackageAvailable, $"{packageId}::{version}", provider); 170Reporter.Output.WriteLine(LocalizableStrings.TemplatePackageCoordinator_BuiltInCheck_Info_UninstallPackage); 171Reporter.Output.WriteCommand( 218Reporter.Output.WriteLine(string.Format(LocalizableStrings.Colon_Separator_Deprecated, split[0], split.Length > 1 ? split[1] : string.Empty).Yellow()); 229Reporter.Error.WriteLine(LocalizableStrings.TemplatePackageCoordinator_Install_Error_FoundNoPackagesToInstall); 241Reporter.Error.WriteLine(LocalizableStrings.TemplatePackageCoordinator_Install_Error_SameInstallRequests, installRequest.PackageIdentifier); 245Reporter.Output.WriteLine(LocalizableStrings.TemplatePackageCoordinator_Install_Info_PackagesToBeInstalled); 248Reporter.Output.WriteLine(installRequest.DisplayName.Indent()); 250Reporter.Output.WriteLine(); 315Reporter.Output.WriteLine(LocalizableStrings.TemplatePackageCoordinator_Update_Info_PackagesToBeUpdated); 318Reporter.Output.WriteLine($"{update.TemplatePackage!.Identifier}::{update.LatestVersion}".Indent()); 320Reporter.Output.WriteLine(); 346Reporter.Output.WriteLine(LocalizableStrings.TemplatePackageCoordinator_Update_Info_AllPackagesAreUpToDate); 378Reporter.Output.WriteLine(LocalizableStrings.TemplatePackageCoordinator_Uninstall_Info_Success, uninstallResult.TemplatePackage.DisplayName); 382Reporter.Error.WriteLine(LocalizableStrings.TemplatePackageCoordinator_Uninstall_Error_GenericError, uninstallResult.TemplatePackage.DisplayName, uninstallResult.ErrorMessage); 438DisplayLocalPackageMetadata(localPackage, Reporter.Output); 441DisplayPackageTemplateList(templatesToDisplay, Reporter.Output); 463DisplayNuGetPackageMetadata(nuGetPackageMetadata, Reporter.Output); 467DisplayPackageTemplateList(templatesToDisplay, Reporter.Output); 472Reporter.Output.WriteLine( 596Reporter.Verbose.WriteLine(LocalizableStrings.TemplatePackageCoordinator_Verbose_NuGetCredentialServiceError, ex.ToString()); 630IReporter reporter = args.Force ? Reporter.Output : Reporter.Error; 718Reporter.Error.WriteLine( 728Reporter.Error.WriteLine(LocalizableStrings.TemplatePackageCoordinator_Error_TemplateIncludedToPackages, notFoundPackage); 733Reporter.Error.WriteLine( 739Reporter.Error.WriteLine(LocalizableStrings.TemplatePackageCoordinator_Uninstall_Error_UninstallCommandHeader); 743Reporter.Error.WriteCommand( 751Reporter.Error.WriteCommand( 760Reporter.Error.WriteLine(LocalizableStrings.TemplatePackageCoordinator_Uninstall_Error_ListPackagesHeader); 761Reporter.Error.WriteCommand( 769Reporter.Error.WriteLine(LocalizableStrings.TemplatePackageCoordinator_Uninstall_Error_ListPackagesHeader); 770Reporter.Error.WriteCommand( 775Reporter.Error.WriteLine(); 825Reporter.Output.WriteLine(LocalizableStrings.TemplatePackageCoordinator_Update_Info_UpdateAvailablePackages); 839Reporter.Output.WriteLine(formatter.Layout()); 840Reporter.Output.WriteLine(); 842Reporter.Output.WriteLine(LocalizableStrings.TemplatePackageCoordinator_Update_Info_UpdateSingleCommandHeader); 843Reporter.Output.WriteCommand( 848Reporter.Output.WriteCommand( 853Reporter.Output.WriteLine(); 854Reporter.Output.WriteLine(LocalizableStrings.TemplatePackageCoordinator_Update_Info_UpdateAllCommandHeader); 855Reporter.Output.WriteCommand( 859Reporter.Output.WriteLine(); 871Reporter.Error.WriteLine(); 882Reporter.Output.WriteLine(LocalizableStrings.TemplatePackageCoordinator_Uninstall_Info_InstalledItems); 886Reporter.Output.WriteLine(LocalizableStrings.NoItems); 892Reporter.Output.WriteLine($"{managedSource.Identifier}".Indent()); 895Reporter.Output.WriteLine($"{LocalizableStrings.Version} {managedSource.Version}".Indent(level: 2)); 901Reporter.Output.WriteLine(LocalizableStrings.TemplatePackageCoordinator_Uninstall_Info_DetailsHeader.Indent(level: 2)); 904Reporter.Output.WriteLine($"{detail.Key}: {GetFormattedValue(detail.Value)}".Indent(level: 3)); 911Reporter.Output.WriteLine($"{LocalizableStrings.Templates}:".Indent(level: 2)); 914Reporter.Output.WriteLine(info.GetDisplayName().Indent(level: 3)); 919Reporter.Output.WriteLine($"{LocalizableStrings.TemplatePackageCoordinator_Uninstall_Info_UninstallCommandHint}".Indent(level: 2)); 920Reporter.Output.WriteCommand( 927Reporter.Output.WriteLine(); 959Reporter.Output.WriteLine(LocalizableStrings.TemplatePackageCoordinator_lnstall_Info_Success, result.TemplatePackage.DisplayName); 964reporter: Reporter.Output); 969Reporter.Output.WriteLine(LocalizableStrings.TemplatePackageCoordinator_lnstall_Warning_No_Templates_In_Package, result.TemplatePackage.DisplayName); 977Reporter.Error.WriteLine( 984Reporter.Error.WriteLine( 990Reporter.Error.WriteLine( 996Reporter.Error.WriteLine( 1002Reporter.Error.WriteLine( 1006Reporter.Error.WriteLine(LocalizableStrings.TemplatePackageCoordinator_lnstall_Error_AlreadyInstalled_Hint, BaseInstallCommand.ForceOption.Aliases.First()); 1007Reporter.Error.WriteCommand(Example.For<InstallCommand>(parseResult).WithArgument(BaseInstallCommand.NameArgument, packageToInstall).WithOption(BaseInstallCommand.ForceOption)); 1011Reporter.Error.WriteLine( 1017Reporter.Error.WriteLine( 1024Reporter.Error.WriteLine( 1043Reporter.Output.WriteLine(LocalizableStrings.TemplatePackageCoordinator_Install_ConstraintsNotice); 1048Reporter.Output.WriteLine(template.Template.GetDisplayName(showIdentity: showIdentity)); 1051Reporter.Output.WriteLine(constraintResult.ToDisplayString().Indent(1)); 1061Reporter.Error.WriteLine( 1069Reporter.Error.WriteLine( 1076Reporter.Error.WriteLine( 1083Reporter.Error.WriteLine( 1131Reporter.Verbose.WriteLine($"Custom source {source} is already loaded from default configuration."); 1137Reporter.Output.WriteLine(string.Format(LocalizableStrings.DetailsCommand_UnableToLoadResource, source));
TemplatePackageDisplay.cs (22)
228Reporter.Output.WriteLine(LocalizableStrings.TemplatePackageCoordinator_Uninstall_Info_InstalledItems); 232Reporter.Output.WriteLine(LocalizableStrings.NoItems); 238Reporter.Output.WriteLine($"{managedSource.Identifier}".Indent()); 241Reporter.Output.WriteLine($"{LocalizableStrings.Version} {managedSource.Version}".Indent(level: 2)); 247Reporter.Output.WriteLine(LocalizableStrings.TemplatePackageCoordinator_Uninstall_Info_DetailsHeader.Indent(level: 2)); 250Reporter.Output.WriteLine($"{detail.Key}: {GetFormattedValue(detail.Value)}".Indent(level: 3)); 257Reporter.Output.WriteLine($"{LocalizableStrings.Templates}:".Indent(level: 2)); 260Reporter.Output.WriteLine(info.GetDisplayName().Indent(level: 3)); 265Reporter.Output.WriteLine($"{LocalizableStrings.TemplatePackageCoordinator_Uninstall_Info_UninstallCommandHint}".Indent(level: 2)); 266Reporter.Output.WriteCommand( 273Reporter.Output.WriteLine(); 284Reporter.Output.WriteLine(LocalizableStrings.TemplatePackageCoordinator_Update_Info_UpdateAvailablePackages); 298Reporter.Output.WriteLine(formatter.Layout()); 299Reporter.Output.WriteLine(); 301Reporter.Output.WriteLine(LocalizableStrings.TemplatePackageCoordinator_Update_Info_UpdateSingleCommandHeader); 302Reporter.Output.WriteCommand( 307Reporter.Output.WriteCommand( 312Reporter.Output.WriteLine(); 313Reporter.Output.WriteLine(LocalizableStrings.TemplatePackageCoordinator_Update_Info_UpdateAllCommandHeader); 314Reporter.Output.WriteCommand( 318Reporter.Output.WriteLine(); 330Reporter.Error.WriteLine();
TemplateSearch\CliHostSearchCacheData.cs (2)
38Reporter.Verbose.WriteLine($"Error deserializing the cli host specific template data for template {data.Name}, details:{ex}"); 45Reporter.Verbose.WriteLine($"Error deserializing the cli host specific template data {cacheObject}, details:{ex}");
TemplateSearch\CliTemplateSearchCoordinator.cs (21)
45Reporter.Output.WriteLine(LocalizableStrings.CliTemplateSearchCoordinator_Info_SearchInProgress); 59Reporter.Error.WriteLine(LocalizableStrings.CliTemplateSearchCoordinator_Error_NoSources.Bold().Red()); 67Reporter.Error.WriteLine(LocalizableStrings.CliTemplateSearchCoordinator_Info_MatchesFromSource, result.Provider.Factory.DisplayName); 68Reporter.Error.WriteLine(string.Format(LocalizableStrings.CliTemplateSearchCoordinator_Error_SearchFailure, result.ErrorMessage).Red().Bold()); 72Reporter.Output.WriteLine(LocalizableStrings.CliTemplateSearchCoordinator_Info_MatchesFromSource, result.Provider.Factory.DisplayName); 82Reporter.Error.WriteLine( 89Reporter.Output.WriteLine(); 93Reporter.Output.WriteLine(LocalizableStrings.CliTemplateSearchCoordinator_Info_InstallHelp); 94Reporter.Output.WriteCommand( 99Reporter.Output.WriteLine(LocalizableStrings.Generic_ExampleHeader); 100Reporter.Output.WriteCommand( 181Reporter.Output.WriteLine(LocalizableStrings.TemplatesFoundMatchingInputParameters, GetInputParametersString(commandArgs)); 182Reporter.Output.WriteLine(); 202Reporter.Output.WriteLine(formatter.Layout()); 255Reporter.Error.WriteLine(LocalizableStrings.CliTemplateSearchCoordinator_Error_NoTemplateName.Red().Bold()); 256Reporter.Error.WriteLine(LocalizableStrings.CliTemplateSearchCoordinator_Info_SearchHelp, string.Join(", ", BaseSearchCommand.SupportedFilters.Select(f => $"'{f.OptionFactory().Name}'"))); 257Reporter.Error.WriteLine(LocalizableStrings.Generic_ExamplesHeader); 258Reporter.Error.WriteCommand( 264Reporter.Error.WriteCommand( 270Reporter.Error.WriteCommand( 282Reporter.Error.WriteLine(LocalizableStrings.CliTemplateSearchCoordinator_Error_TemplateNameIsTooShort.Bold().Red());
Microsoft.TemplateEngine.Cli.UnitTests (2)
PostActionTests\AddJsonPropertyPostActionTests.cs (2)
51Reporter.SetError(mockReporter.Object); 120Reporter.SetError(mockReporter.Object);