97 writes to Command
aspire (16)
Projects\JavaAppHostToolchainResolver.cs (3)
837
Command
= baseCompile.Command,
873
Command
= "java",
893
Command
= Command,
Projects\TypeScriptAppHostToolchainResolver.cs (13)
204
Command
= GetCommandName(toolchain),
217
Command
= "bun",
222
Command
= "yarn",
227
Command
= "pnpm",
235
Command
= "deno",
249
Command
= "bun",
254
Command
= "yarn",
259
Command
= "pnpm",
268
Command
= "deno",
281
Command
= "bun",
296
Command
= "yarn",
311
Command
= "pnpm",
329
Command
= "deno",
Aspire.Cli.Tests (65)
Projects\GuestAppHostProjectTests.cs (5)
181
Execute = new CommandSpec {
Command
= guestInstaller, Args = [] },
182
InstallDependencies = new CommandSpec {
Command
= guestInstaller, Args = [] }
1173
Execute = new CommandSpec {
Command
= "unused", Args = [] },
1176
Command
= OperatingSystem.IsWindows() ? Path.Combine(Environment.SystemDirectory, "cmd.exe") : "/bin/sh",
2075
Execute = new CommandSpec {
Command
= "node", Args = ["apphost.js"] },
Projects\GuestRuntimeTests.cs (52)
60
Command
= "test-cmd",
75
Command
= "npx",
82
Command
= "npx",
119
Command
= "my-runner",
138
execute: new CommandSpec {
Command
= "run-cmd", Args = ["{appHostFile}"] },
139
watchExecute: new CommandSpec {
Command
= "watch-cmd", Args = ["--watch", "{appHostFile}"] }
156
execute: new CommandSpec {
Command
= "run-cmd", Args = ["{appHostFile}"] },
157
watchExecute: new CommandSpec {
Command
= "watch-cmd", Args = ["--watch", "{appHostFile}"] },
160
new CommandSpec {
Command
= "typecheck-cmd", Args = ["--noEmit"] }
178
execute: new CommandSpec {
Command
= "run-cmd", Args = ["{appHostFile}"] },
181
new CommandSpec {
Command
= "typecheck-cmd", Args = ["--project", "{appHostDir}"] }
224
execute: new CommandSpec {
Command
= "run-cmd", Args = ["{appHostFile}"] },
227
new CommandSpec {
Command
= "typecheck-cmd", Args = ["--project", "{appHostDir}"] }
268
Command
= "npx",
275
Command
= "npx",
319
execute: new CommandSpec {
Command
= "run-cmd", Args = ["{appHostFile}"] },
322
new CommandSpec {
Command
= "typecheck-cmd", Args = ["--noEmit"] }
353
var spec = CreateTestSpec(execute: new CommandSpec {
Command
= "missing-cmd", Args = ["{appHostFile}"] });
380
var spec = CreateTestSpec(execute: new CommandSpec {
Command
= "run-cmd", Args = ["{appHostFile}"] });
395
execute: new CommandSpec {
Command
= "run-cmd", Args = ["{appHostFile}"] },
396
publishExecute: new CommandSpec {
Command
= "publish-cmd", Args = ["{appHostFile}", "{args}"] }
413
execute: new CommandSpec {
Command
= "run-cmd", Args = ["{appHostFile}"] },
414
publishExecute: new CommandSpec {
Command
= "publish-cmd", Args = ["{appHostFile}", "{args}"] },
417
new CommandSpec {
Command
= "typecheck-cmd", Args = ["--project", "{appHostDir}"] }
435
execute: new CommandSpec {
Command
= "run-cmd", Args = ["{appHostFile}"] },
436
publishExecute: new CommandSpec {
Command
= "publish-cmd", Args = ["{appHostFile}", "{args}"] },
439
new CommandSpec {
Command
= "typecheck-cmd", Args = ["--project", "{appHostDir}"] }
494
var spec = CreateTestSpec(execute: new CommandSpec {
Command
= "run-cmd", Args = ["{appHostFile}"] });
510
Command
= "test-cmd",
531
Command
= "test-cmd",
551
Command
= "test-cmd",
582
Command
= "java",
590
Command
= "java",
635
Command
= "npx",
654
Command
= "test-cmd",
672
Command
= "test-cmd",
692
Command
= "test-cmd",
714
Execute = new CommandSpec {
Command
= "test-cmd", Args = ["{appHostFile}"] },
751
new CommandSpec {
Command
= "dotnet", Args = ["--version"] },
752
new CommandSpec {
Command
= "aspire-command-that-does-not-exist", Args = [] }
803
Command
= command,
812
Command
= command,
848
Execute = new CommandSpec {
Command
= "npx", Args = ["tsx", "{appHostFile}"] },
851
Command
= "npm",
884
Command
= "npx",
1149
Command
= "test-cmd",
1197
Command
= "test-cmd",
1223
Command
= "test-cmd",
1444
execute: new CommandSpec {
Command
= "java", Args = ["AppHost"] },
1449
Command
= "javac",
1599
execute: new CommandSpec {
Command
= "java", Args = ["AppHost"] },
1604
Command
= "javac",
Projects\JavaAppHostToolchainResolverTests.cs (3)
60
Command
= "javac",
66
Command
= "java",
205
Command
= baseCompile.Command,
Projects\TypeScriptAppHostToolchainResolverTests.cs (4)
448
Command
= "npm",
455
Command
= "npx",
461
Command
= "npx",
466
Command
= "npx",
TestServices\FakeAppHostServerSession.cs (1)
143
Execute = new CommandSpec {
Command
= "node", Args = ["apphost.js"] }
Aspire.Hosting.CodeGeneration.Go (1)
GoLanguageSupport.cs (1)
142
Command
= "go",
Aspire.Hosting.CodeGeneration.Java (2)
JavaLanguageSupport.cs (2)
295
Command
= "javac",
318
Command
= "java",
Aspire.Hosting.CodeGeneration.Java.Tests (1)
JavaLanguageSupportTests.cs (1)
54
Command
= "javac",
Aspire.Hosting.CodeGeneration.Python (7)
PythonLanguageSupport.cs (7)
185
Command
= "uv",
191
Command
= "uv",
196
Command
= "uv",
221
Command
= python,
226
Command
= s_venvPython,
232
Command
= s_venvPython,
237
Command
= s_venvPython,
Aspire.Hosting.CodeGeneration.Rust (1)
RustLanguageSupport.cs (1)
145
Command
= "cargo",
Aspire.Hosting.CodeGeneration.TypeScript (4)
TypeScriptLanguageSupport.cs (4)
261
Command
= "npm",
268
Command
= "npx",
274
Command
= "npx",
279
Command
= "npx",
43 references to Command
aspire (13)
Projects\GuestAppHostProject.cs (1)
2478
runtimeSpec.Execute.
Command
,
Projects\GuestRuntime.cs (11)
112
using var activity = _profilingTelemetry.StartGuestInitializeCommand(_spec.Language, _spec.DisplayName, commandSpec.
Command
, args, directory);
114
commandSpec.
Command
,
162
command.
Command
,
166
command.
Command
,
296
_logger.LogDebug("Skipping up-to-date pre-execution command: {Command}", commandSpec.
Command
);
300
_logger.LogDebug("Launching pre-execution command: {Command} {Args}", commandSpec.
Command
, string.Join(" ", args));
301
using var activity = _profilingTelemetry.StartGuestExecuteCommand(_spec.Language, _spec.DisplayName, commandSpec.
Command
, args, directory, ProfilingTelemetry.Values.GuestCommandPhasePreExecute);
302
var (exitCode, output) = await preExecuteLauncher.LaunchAsync(commandSpec.
Command
, args, directory, mergedEnvironment, afterLaunchAsync: null, options: null, cancellationToken);
591
_logger.LogDebug("Launching: {Command} {Args}", commandSpec.
Command
, string.Join(" ", args));
592
using var activity = _profilingTelemetry.StartGuestExecuteCommand(_spec.Language, _spec.DisplayName, commandSpec.
Command
, args, directory, phase);
593
var (exitCode, output) = await launcher.LaunchAsync(commandSpec.
Command
, args, directory, mergedEnvironment, afterLaunchAsync: afterLaunchAsync, options: launchOptions, cancellationToken);
Projects\JavaAppHostToolchainResolver.cs (1)
837
Command = baseCompile.
Command
,
Aspire.Cli.Tests (24)
Projects\JavaAppHostToolchainResolverTests.cs (9)
30
Assert.Equal(Environment.GetEnvironmentVariable("ComSpec") ?? "cmd.exe", actual.
Command
);
40
Assert.Equal("sh", actual.
Command
);
155
Assert.Equal("javac", compile.
Command
);
169
Assert.Equal("java", spec.Execute.
Command
);
205
Command = baseCompile.
Command
,
258
Assert.Equal("javac", compile.
Command
);
270
Assert.Equal("java", spec.Execute.
Command
);
632
var startInfo = new ProcessStartInfo(command.
Command
)
650
using var process = Process.Start(startInfo) ?? throw new InvalidOperationException($"Failed to start '{command.
Command
}'.");
Projects\TypeScriptAppHostToolchainResolverTests.cs (15)
357
Assert.Equal("bun", runtimeSpec.InstallDependencies?.
Command
);
360
Assert.Equal("bun", preExecute.
Command
);
362
Assert.Equal("bun", runtimeSpec.Execute.
Command
);
365
Assert.Equal("bun", runtimeSpec.WatchExecute?.
Command
);
390
Assert.Equal("yarn", preExecute.
Command
);
392
Assert.Equal("yarn", runtimeSpec.Execute.
Command
);
394
Assert.Equal("yarn", runtimeSpec.WatchExecute?.
Command
);
406
Assert.Equal("pnpm", installDependencies.
Command
);
409
Assert.Equal("pnpm", preExecute.
Command
);
411
Assert.Equal("pnpm", runtimeSpec.Execute.
Command
);
413
Assert.Equal("pnpm", runtimeSpec.WatchExecute?.
Command
);
425
Assert.Equal("deno", runtimeSpec.InstallDependencies?.
Command
);
428
Assert.Equal("deno", preExecute.
Command
);
430
Assert.Equal("deno", runtimeSpec.Execute.
Command
);
432
Assert.Equal("deno", runtimeSpec.WatchExecute?.
Command
);
Aspire.Hosting.CodeGeneration.Rust.Tests (1)
RustLanguageSupportTests.cs (1)
87
Assert.Equal("cargo", runtimeSpec.Execute.
Command
);
Aspire.Hosting.CodeGeneration.TypeScript.Tests (2)
TypeScriptLanguageSupportTests.cs (2)
261
Assert.Equal("npx", preExecute.
Command
);
299
Assert.Equal("npx", provider.GetRuntimeSpec().Execute.
Command
);
Aspire.Hosting.RemoteHost (1)
Language\IntegrationHostProcessLauncher.cs (1)
41
if (!CommandPathResolver.TryResolveCommand(hostSpec.Execute.
Command
, out var command, out var error))
Aspire.Hosting.RemoteHost.Tests (2)
CodeGenerationResolverTests.cs (2)
102
Assert.Equal("node", spec.Execute.
Command
);
105
Assert.Equal("npm", spec.InstallDependencies.
Command
);