-
Notifications
You must be signed in to change notification settings - Fork 166
Labels
📌 seQUESTeredIdentifies that an issue has been imported into Quest.Identifies that an issue has been imported into Quest.dotnet-aspire/svc
Description
Type of issue
Typo
Description
First congrats on another release 🚀
While reading the release post, I noticed a snippet that doesn't compile on Aspire 9.5 nor Aspire 9.5.1
The snippet can be found at https://learn.microsoft.com/en-us/dotnet/aspire/whats-new/dotnet-aspire-9.5#withcommand-and-withworkingdirectory-apis
// Configure executable with custom command and working directory
var processor = builder.AddExecutable("data-processor", "python")
.WithCommand("main.py --batch-size 100")
.WithWorkingDirectory("/app/data-processing")
.WithArgs("--config", "production.json");
// Executable with specific working directory for relative paths
var buildTool = builder.AddExecutable("build-tool", "npm")
.WithCommand("run build:production")
.WithWorkingDirectory("./frontend");
Throws the error:
No overload for method 'AddExecutable' takes 2 arguments[CS1501](https://msdn.microsoft.com/query/roslyn.query?appId=roslyn&k=k(CS1501))
The working directory is the 3rd argument of AddExecutable
and I think that should fix it.
But then, it doesn't make sense to add it to the "WithCommand and WithWorkingDirectory APIs" section.
// Configure executable with custom command and working directory
var processor = builder.AddExecutable("data-processor", "python", "/app/data-processing")
.WithCommand("main.py --batch-size 100")
.WithArgs("--config", "production.json");
// Executable with specific working directory for relative paths
var buildTool = builder.AddExecutable("build-tool", "npm", "run build:production")
.WithWorkingDirectory("./frontend");
Page URL
https://learn.microsoft.com/en-us/dotnet/aspire/whats-new/dotnet-aspire-9.5
Content source URL
https://github.com/dotnet/docs-aspire/blob/main/docs/whats-new/dotnet-aspire-9.5.md
Document Version Independent Id
e2e991b9-430a-41da-7b32-7c111e952fae
Platform Id
912ec644-ff51-25d7-c01c-7208e400c144
Article author
IEvangelistCopilot
Metadata
Metadata
Assignees
Labels
📌 seQUESTeredIdentifies that an issue has been imported into Quest.Identifies that an issue has been imported into Quest.dotnet-aspire/svc
Type
Projects
Status
👀 In review