Skip to content

Commit

Permalink
Remove console events usage from runner core
Browse files Browse the repository at this point in the history
  • Loading branch information
SaifAqqad committed May 31, 2024
1 parent 5f160a0 commit db021ac
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 0 additions & 1 deletion src/AspireRunner.Core/Helpers/DotnetCli.cs
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,6 @@ public Process Run(string[] arguments, string? workingDirectory = null, IDiction
throw new InvalidOperationException("Failed to start dotnet process");
}

Console.CancelKeyPress += (_, _) => process.Kill(true);
if (outputHandler != null)
{
process.OutputDataReceived += (_, e) =>
Expand Down
2 changes: 2 additions & 0 deletions src/AspireRunner.Tool/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,8 @@
logger.LogDebug("Dashboard options: {@DashboardOptions}", JsonSerializer.Serialize(dashboardOptions));

var aspireDashboard = new AspireDashboard(dotnet, nugetHelper, dashboardOptions, logger);

Console.CancelKeyPress += (_, _) => aspireDashboard.Stop();
aspireDashboard.DashboardStarted += url => logger.LogInformation(Green("The Aspire Dashboard is ready at {Url}"), url);

var (isInstalled, _) = aspireDashboard.IsInstalled();
Expand Down

0 comments on commit db021ac

Please sign in to comment.