108 instantiations of Process
aspire (13)
Agents\ClaudeCode\ClaudeCodeCliRunner.cs (1)
38using var process = new Process { StartInfo = startInfo };
Agents\CopilotCli\CopilotCliRunner.cs (1)
38using var process = new Process { StartInfo = startInfo };
Agents\OpenCode\OpenCodeCliRunner.cs (1)
38using var process = new Process { StartInfo = startInfo };
Agents\Playwright\PlaywrightCliRunner.cs (2)
35using var process = new Process { StartInfo = startInfo }; 104using var process = new Process { StartInfo = startInfo };
Agents\VsCode\VsCodeCliRunner.cs (1)
39using var process = new Process { StartInfo = startInfo };
DotNet\DotNetCliExecutionFactory.cs (1)
92var process = new Process { StartInfo = startInfo };
DotNet\DotNetSdkInstaller.cs (1)
32using var process = new Process
Git\GitRepository.cs (1)
32using var process = new Process { StartInfo = startInfo };
Layout\LayoutProcessRunner.cs (1)
81var process = new Process();
Npm\NpmRunner.cs (1)
247using var process = new Process { StartInfo = startInfo };
OpenCode\OpenCodeCliRunner.cs (1)
31using var process = new Process { StartInfo = startInfo };
Projects\ProcessGuestLauncher.cs (1)
66using var process = new Process { StartInfo = startInfo };
Aspire.Cli.EndToEnd.Tests (2)
KubernetesPublishTests.cs (1)
314using var cleanupProcess = new System.Diagnostics.Process();
tests\Shared\TemporaryRepo.cs (1)
22using var process = new Process
Aspire.Cli.Tests (1)
tests\Shared\TemporaryRepo.cs (1)
22using var process = new Process
Aspire.Deployment.EndToEnd.Tests (28)
AcaCompactNamingDeploymentTests.cs (1)
192var process = new System.Diagnostics.Process
AcaCompactNamingUpgradeDeploymentTests.cs (1)
306var process = new System.Diagnostics.Process
AcaCustomRegistryDeploymentTests.cs (1)
262var process = new System.Diagnostics.Process
AcaDeploymentErrorOutputTests.cs (1)
192var process = new System.Diagnostics.Process
AcaExistingRegistryDeploymentTests.cs (1)
286var process = new System.Diagnostics.Process
AcaManagedRedisDeploymentTests.cs (1)
364var process = new System.Diagnostics.Process
AcaStarterDeploymentTests.cs (1)
231var process = new System.Diagnostics.Process
AcrPurgeTaskDeploymentTests.cs (1)
293var process = new System.Diagnostics.Process
AksStarterDeploymentTests.cs (1)
379var process = new System.Diagnostics.Process
AksStarterWithRedisDeploymentTests.cs (1)
407var process = new System.Diagnostics.Process
AppServicePythonDeploymentTests.cs (1)
216var process = new System.Diagnostics.Process
AppServiceReactDeploymentTests.cs (1)
231var process = new System.Diagnostics.Process
AzureAppConfigDeploymentTests.cs (1)
197var process = new System.Diagnostics.Process
AzureContainerRegistryDeploymentTests.cs (1)
172var process = new System.Diagnostics.Process
AzureEventHubsDeploymentTests.cs (1)
197var process = new System.Diagnostics.Process
AzureKeyVaultDeploymentTests.cs (1)
197var process = new System.Diagnostics.Process
AzureLogAnalyticsDeploymentTests.cs (1)
172var process = new System.Diagnostics.Process
AzureServiceBusDeploymentTests.cs (1)
199var process = new System.Diagnostics.Process
AzureStorageDeploymentTests.cs (1)
204var process = new System.Diagnostics.Process
PythonFastApiDeploymentTests.cs (1)
217var process = new System.Diagnostics.Process
tests\Shared\TemporaryRepo.cs (1)
22using var process = new Process
TypeScriptExpressDeploymentTests.cs (1)
212var process = new System.Diagnostics.Process
VnetKeyVaultConnectivityDeploymentTests.cs (1)
281var process = new System.Diagnostics.Process
VnetKeyVaultInfraDeploymentTests.cs (1)
212var process = new System.Diagnostics.Process
VnetSqlServerConnectivityDeploymentTests.cs (1)
282var process = new System.Diagnostics.Process
VnetSqlServerInfraDeploymentTests.cs (1)
213var process = new System.Diagnostics.Process
VnetStorageBlobConnectivityDeploymentTests.cs (1)
288var process = new System.Diagnostics.Process
VnetStorageBlobInfraDeploymentTests.cs (1)
214var process = new System.Diagnostics.Process
Aspire.EndToEnd.Tests (2)
tests\Shared\TemplatesTesting\AspireProject.cs (1)
178AppHostProcess = new Process();
tests\Shared\TemplatesTesting\ToolCommand.cs (1)
228return new Process
Aspire.Hosting (1)
Dcp\Process\ProcessUtil.cs (1)
22var process = new System.Diagnostics.Process()
Aspire.Hosting.Azure (1)
src\Aspire.Hosting\Dcp\Process\ProcessUtil.cs (1)
22var process = new System.Diagnostics.Process()
Aspire.Hosting.DevTunnels (1)
DevTunnelCli.cs (1)
237using var process = new Process
Aspire.Hosting.Docker (1)
src\Aspire.Hosting\Dcp\Process\ProcessUtil.cs (1)
22var process = new System.Diagnostics.Process()
Aspire.Hosting.Tests (2)
MSBuildTests.cs (2)
226using var process = new Process(); 553using var process = new Process();
Aspire.Templates.Tests (2)
tests\Shared\TemplatesTesting\AspireProject.cs (1)
178AppHostProcess = new Process();
tests\Shared\TemplatesTesting\ToolCommand.cs (1)
228return new Process
dotnet (2)
CommandFactory\CommandFactoryUsingResolver.cs (1)
118var _process = new Process
Commands\Help\HelpCommand.cs (1)
77return new Process
dotnet-format (1)
Utilities\ProcessRunner.cs (1)
77var process = new Process();
dotnet-suggest (1)
SuggestionStore.cs (1)
38using (var process = new Process
dotnet-svcutil-lib (1)
Shared\Utilities\ProcessRunner.cs (1)
68using (var proc = new Process())
dotnet-user-jwts (2)
src\aspnetcore\src\Tools\Shared\SecretsHelpers\ProjectIdResolver.cs (2)
84using var process = new Process() 168using var process = new Process()
dotnet-user-secrets (2)
src\aspnetcore\src\Tools\Shared\SecretsHelpers\ProjectIdResolver.cs (2)
84using var process = new Process() 168using var process = new Process()
Infrastructure.Tests (4)
ExtractTestPartitions\ExtractTestPartitionsFixture.cs (1)
32using var process = new Process { StartInfo = psi };
ExtractTestPartitions\ExtractTestPartitionsTests.cs (1)
313using var process = new Process { StartInfo = psi };
PowerShellScripts\PowerShellCommand.cs (1)
214return new Process
WorkflowScripts\NodeCommand.cs (1)
199return new Process
Microsoft.Agents.AI.ProjectTemplates.Tests (1)
test\ProjectTemplates\Infrastructure\TestCommand.cs (1)
55using var process = new Process
Microsoft.Arcade.Common (1)
Command.cs (1)
43_process = new Process()
Microsoft.AspNetCore.Components.WebView.WindowsForms (1)
src\BlazorWebView\src\SharedSource\WebView2WebViewManager.cs (1)
381 using (var launchBrowser = new Process())
Microsoft.AspNetCore.Components.WebView.Wpf (1)
src\BlazorWebView\src\SharedSource\WebView2WebViewManager.cs (1)
381 using (var launchBrowser = new Process())
Microsoft.AspNetCore.Server.IntegrationTesting (6)
ApplicationPublisher.cs (1)
64var hostProcess = new Process() { StartInfo = startInfo };
Deployers\NginxDeployer.cs (3)
114using (var process = new Process 169using (var runNginx = new Process() { StartInfo = startInfo }) 211using (var runNginx = new Process() { StartInfo = startInfo })
Deployers\RemoteWindowsDeployer\RemoteWindowsDeployer.cs (1)
247using (var runScriptsOnRemoteServerProcess = new Process() { StartInfo = startInfo })
Deployers\SelfHostDeployer.cs (1)
145HostProcess = new Process() { StartInfo = startInfo };
Microsoft.Build.Utilities.Core (1)
ToolTask.cs (1)
786proc = new Process();
Microsoft.DotNet.Cli.Utils (2)
Extensions\ProcessStartInfoExtensions.cs (2)
14var process = new Process 37var process = new Process
Microsoft.DotNet.HotReload.Watch (1)
Process\ProcessRunner.cs (1)
144var process = new Process
Microsoft.DotNet.MacOsPkg.Core (1)
ExecuteHelper.cs (1)
23using (Process process = new Process { StartInfo = processStartInfo })
Microsoft.Extensions.AI.Templates.Tests (1)
test\ProjectTemplates\Infrastructure\TestCommand.cs (1)
55using var process = new Process
Microsoft.Extensions.DataIngestion.MarkItDown (1)
MarkItDownReader.cs (1)
75using (Process process = new() { StartInfo = startInfo })
Microsoft.Extensions.DataIngestion.Tests (1)
Readers\MarkItDownConditionAttribute.cs (1)
36using Process process = new() { StartInfo = startInfo };
Microsoft.McpServer.ProjectTemplates.Tests (1)
test\ProjectTemplates\Infrastructure\TestCommand.cs (1)
55using var process = new Process
Microsoft.ML.CodeGenerator (3)
Utils.cs (3)
195var proc = new System.Diagnostics.Process(); 221var proc = new System.Diagnostics.Process(); 242var proc = new System.Diagnostics.Process();
Microsoft.ML.Sweeper (1)
ConfigRunner.cs (1)
226var p = new System.Diagnostics.Process
Microsoft.NET.Build.Containers (1)
LocalDaemons\DockerCli.cs (1)
294Process proc = new()
Microsoft.NET.Sdk.Publish.Tasks (1)
Tasks\GenerateEFSQLScripts.cs (1)
106proc = new Process
Microsoft.TestPlatform.Build (1)
Tasks\VSTestTask.cs (1)
87using var activeProcess = new Process { StartInfo = processInfo };
Microsoft.TestPlatform.Extensions.BlameDataCollector (1)
ProcessCodeMethods.cs (1)
139Process ps = new();
Microsoft.TestPlatform.PlatformAbstractions (1)
common\System\ProcessHelper.cs (1)
63var process = new Process();
NuGet.Build.Tasks (1)
StaticGraphRestoreTaskBase.cs (1)
117using (var process = new Process())
NuGet.Common (1)
Migrations\Migration1.cs (1)
201using (var proc = new Process())
NuGet.Packaging (1)
NuGetExtractionFileIO.cs (1)
108using (var process = new Process())
NuGet.Protocol (1)
Plugins\PluginProcess.cs (1)
87_process = new Process();
PresentationUI (2)
InstallationError.xaml.cs (1)
211Process Notepad = new Process();
TenFeetInstallationError.xaml.cs (1)
215Process Notepad = new Process();
System.Diagnostics.Process (6)
System\Diagnostics\Process.cs (6)
919return new Process(machineName, isRemoteMachine, processId, null); 936return new Process(".", false, processId, null); 955process = new Process(".", false, processId, null); 1043processes[i] = new Process(machineName, isRemoteMachine, processInfo.ProcessId, processInfo); 1058return new Process(".", false, Environment.ProcessId, null); 1406Process process = new Process();
System.Net.Ping (1)
System\Net\NetworkInformation\Ping.PingUtility.cs (1)
48return new Process() { StartInfo = psi };
804 references to Process
aspire (90)
Agents\ClaudeCode\ClaudeCodeCliRunner.cs (1)
38using var process = new Process { StartInfo = startInfo };
Agents\CopilotCli\CopilotCliRunner.cs (1)
38using var process = new Process { StartInfo = startInfo };
Agents\OpenCode\OpenCodeCliRunner.cs (1)
38using var process = new Process { StartInfo = startInfo };
Agents\Playwright\PlaywrightCliRunner.cs (2)
35using var process = new Process { StartInfo = startInfo }; 104using var process = new Process { StartInfo = startInfo };
Agents\VsCode\VsCodeCliRunner.cs (1)
39using var process = new Process { StartInfo = startInfo };
Certificates\CertificateGeneration\MacOSCertificateManager.cs (12)
104using (var process = Process.Start(MacOSTrustCertificateCommandLine, s_macOSTrustCertificateCommandLineArguments + tmpFile)) 159using var checkTrustProcess = Process.Start(new ProcessStartInfo( 214using var process = Process.Start(processInfo); 257using (var process = Process.Start(processInfo)) 288using var findCertificateProcess = Process.Start(new ProcessStartInfo( 358using (var process = Process.Start(processInfo))
Certificates\CertificateGeneration\UnixCertificateManager.cs (12)
694using var process = Process.Start(startInfo)!; 717using var process = Process.Start(startInfo)!; 746using var process = Process.Start(startInfo)!; 770using var process = Process.Start(startInfo)!; 942using var process = Process.Start(processInfo); 986using var process = Process.Start(processInfo);
Certificates\CertificateHelpers.cs (2)
100using var process = Process.Start(processInfo);
Commands\AppHostLauncher.cs (2)
215private record LaunchResult(Process? ChildProcess, IAppHostAuxiliaryBackchannel? Backchannel, DashboardUrlsState? DashboardUrls, bool ChildExitedEarly, int ChildExitCode); 223Process childProcess;
Commands\StopCommand.cs (2)
296using var process = Process.GetProcessById(pid);
Commands\UpdateCommand.cs (2)
501using var process = Process.Start(psi);
DotNet\DotNetCliExecution.cs (2)
14private readonly Process _process; 20internal DotNetCliExecution(Process process, ILogger logger, DotNetCliRunnerInvocationOptions options)
DotNet\DotNetCliExecutionFactory.cs (2)
22var startTime = Process.GetCurrentProcess().StartTime; 92var process = new Process { StartInfo = startInfo };
DotNet\DotNetSdkInstaller.cs (1)
32using var process = new Process
Git\GitRepository.cs (1)
32using var process = new Process { StartInfo = startInfo };
Layout\LayoutProcessRunner.cs (5)
42using var process = CreateProcess(toolPath, arguments, workingDirectory, environmentVariables, redirectOutput: true); 58public static Process Start( 65var process = CreateProcess(toolPath, arguments, workingDirectory, environmentVariables, redirectOutput); 74private static Process CreateProcess( 81var process = new Process();
Npm\NpmRunner.cs (1)
247using var process = new Process { StartInfo = startInfo };
OpenCode\OpenCodeCliRunner.cs (1)
31using var process = new Process { StartInfo = startInfo };
Processes\DetachedProcessLauncher.cs (2)
70/// <returns>A <see cref="Process"/> object representing the launched child.</returns> 71public static Process Start(string fileName, IReadOnlyList<string> arguments, string workingDirectory)
Processes\DetachedProcessLauncher.Unix.cs (3)
18private static Process StartUnix(string fileName, IReadOnlyList<string> arguments, string workingDirectory) 36var process = Process.Start(startInfo)
Processes\DetachedProcessLauncher.Windows.cs (3)
20private static Process StartWindows(string fileName, IReadOnlyList<string> arguments, string workingDirectory) 106Process detachedProcess; 109detachedProcess = Process.GetProcessById(pi.dwProcessId);
Program.cs (2)
707var currentProcess = Process.GetCurrentProcess();
Projects\AppHostServerSession.cs (3)
17private readonly Process _serverProcess; 24Process serverProcess, 39public Process ServerProcess => _serverProcess;
Projects\DotNetBasedAppHostServerProject.cs (5)
467public (string SocketPath, Process Process, OutputCollector OutputCollector) Run( 520var process = Process.Start(startInfo)!; 559using var process = Process.Start(startInfo);
Projects\GuestAppHostProject.cs (1)
938Process process,
Projects\IAppHostServerProject.cs (1)
58(string SocketPath, Process Process, OutputCollector OutputCollector) Run(
Projects\IAppHostServerSession.cs (1)
25Process ServerProcess { get; }
Projects\PrebuiltAppHostServer.cs (3)
404public (string SocketPath, Process Process, OutputCollector OutputCollector) Run( 482var process = Process.Start(startInfo)!;
Projects\ProcessGuestLauncher.cs (1)
66using var process = new Process { StartInfo = startInfo };
Projects\RunningInstanceManager.cs (2)
111var process = Process.GetProcessById(pid);
src\Shared\BackchannelConstants.cs (2)
251using var process = Process.GetProcessById(pid);
Utils\CliDownloader.cs (2)
132using var process = Process.Start(psi);
Utils\EnvironmentChecker\ContainerRuntimeCheck.cs (6)
101using var versionProcess = Process.Start(versionProcessInfo); 250using var psProcess = Process.Start(psProcessInfo); 465using var process = Process.Start(processInfo);
Utils\EnvironmentChecker\DeprecatedWorkloadCheck.cs (2)
36using var process = Process.Start(processInfo);
Aspire.Cli.EndToEnd.Tests (2)
KubernetesPublishTests.cs (1)
314using var cleanupProcess = new System.Diagnostics.Process();
tests\Shared\TemporaryRepo.cs (1)
22using var process = new Process
Aspire.Cli.Tests (1)
tests\Shared\TemporaryRepo.cs (1)
22using var process = new Process
Aspire.Deployment.EndToEnd.Tests (28)
AcaCompactNamingDeploymentTests.cs (1)
192var process = new System.Diagnostics.Process
AcaCompactNamingUpgradeDeploymentTests.cs (1)
306var process = new System.Diagnostics.Process
AcaCustomRegistryDeploymentTests.cs (1)
262var process = new System.Diagnostics.Process
AcaDeploymentErrorOutputTests.cs (1)
192var process = new System.Diagnostics.Process
AcaExistingRegistryDeploymentTests.cs (1)
286var process = new System.Diagnostics.Process
AcaManagedRedisDeploymentTests.cs (1)
364var process = new System.Diagnostics.Process
AcaStarterDeploymentTests.cs (1)
231var process = new System.Diagnostics.Process
AcrPurgeTaskDeploymentTests.cs (1)
293var process = new System.Diagnostics.Process
AksStarterDeploymentTests.cs (1)
379var process = new System.Diagnostics.Process
AksStarterWithRedisDeploymentTests.cs (1)
407var process = new System.Diagnostics.Process
AppServicePythonDeploymentTests.cs (1)
216var process = new System.Diagnostics.Process
AppServiceReactDeploymentTests.cs (1)
231var process = new System.Diagnostics.Process
AzureAppConfigDeploymentTests.cs (1)
197var process = new System.Diagnostics.Process
AzureContainerRegistryDeploymentTests.cs (1)
172var process = new System.Diagnostics.Process
AzureEventHubsDeploymentTests.cs (1)
197var process = new System.Diagnostics.Process
AzureKeyVaultDeploymentTests.cs (1)
197var process = new System.Diagnostics.Process
AzureLogAnalyticsDeploymentTests.cs (1)
172var process = new System.Diagnostics.Process
AzureServiceBusDeploymentTests.cs (1)
199var process = new System.Diagnostics.Process
AzureStorageDeploymentTests.cs (1)
204var process = new System.Diagnostics.Process
PythonFastApiDeploymentTests.cs (1)
217var process = new System.Diagnostics.Process
tests\Shared\TemporaryRepo.cs (1)
22using var process = new Process
TypeScriptExpressDeploymentTests.cs (1)
212var process = new System.Diagnostics.Process
VnetKeyVaultConnectivityDeploymentTests.cs (1)
281var process = new System.Diagnostics.Process
VnetKeyVaultInfraDeploymentTests.cs (1)
212var process = new System.Diagnostics.Process
VnetSqlServerConnectivityDeploymentTests.cs (1)
282var process = new System.Diagnostics.Process
VnetSqlServerInfraDeploymentTests.cs (1)
213var process = new System.Diagnostics.Process
VnetStorageBlobConnectivityDeploymentTests.cs (1)
288var process = new System.Diagnostics.Process
VnetStorageBlobInfraDeploymentTests.cs (1)
214var process = new System.Diagnostics.Process
Aspire.EndToEnd.Tests (5)
tests\Shared\TemplatesTesting\AspireProject.cs (1)
26public Process? AppHostProcess { get; private set; }
tests\Shared\TemplatesTesting\TestExtensions.cs (2)
20public static bool TryGetHasExited(this Process process) 32public static void CloseAndKillProcessIfRunning(this Process process)
tests\Shared\TemplatesTesting\ToolCommand.cs (2)
19public Process? CurrentProcess { get; private set; } 208private Process CreateProcess(string executable, string args)
Aspire.Hosting (11)
ApplicationModel\ProjectRebuilderResource.cs (1)
10/// This uses a DCP executable resource rather than <see cref="System.Diagnostics.Process"/> directly
Backchannel\AuxiliaryBackchannelRpcTarget.cs (1)
362StartedAt = new DateTimeOffset(Process.GetCurrentProcess().StartTime)
Cli\CliOrphanDetector.cs (3)
17return !Process.GetProcessById(pid).HasExited; 30var process = Process.GetProcessById(pid);
Dashboard\DashboardEventHandlers.cs (1)
100var mainModule = Process.GetCurrentProcess().MainModule;
Dcp\Process\ProcessUtil.cs (3)
22var process = new System.Diagnostics.Process() 137private readonly System.Diagnostics.Process _process; 141public ProcessDisposable(System.Diagnostics.Process process, Task processLifetimeTask, bool entireProcessTree)
src\Shared\BackchannelConstants.cs (2)
251using var process = Process.GetProcessById(pid);
Aspire.Hosting.Azure (3)
src\Aspire.Hosting\Dcp\Process\ProcessUtil.cs (3)
22var process = new System.Diagnostics.Process() 137private readonly System.Diagnostics.Process _process; 141public ProcessDisposable(System.Diagnostics.Process process, Task processLifetimeTask, bool entireProcessTree)
Aspire.Hosting.DevTunnels (1)
DevTunnelCli.cs (1)
237using var process = new Process
Aspire.Hosting.Docker (3)
src\Aspire.Hosting\Dcp\Process\ProcessUtil.cs (3)
22var process = new System.Diagnostics.Process() 137private readonly System.Diagnostics.Process _process; 141public ProcessDisposable(System.Diagnostics.Process process, Task processLifetimeTask, bool entireProcessTree)
Aspire.Hosting.JavaScript.Tests (4)
AddJavaScriptAppTests.cs (4)
136using var process = Process.Start(processStartInfo); 147using var cleanupProcess = Process.Start(new ProcessStartInfo
Aspire.Hosting.Maui (2)
Utilities\ProjectFileReader.cs (2)
70using var process = Process.Start(startInfo);
Aspire.Hosting.Python (2)
PythonVersionDetector.cs (2)
78using var process = Process.Start(startInfo);
Aspire.Hosting.Python.Tests (4)
AddPythonAppTests.cs (4)
316var createVirtualEnvironmentProcess = Process.Start(prepareVirtualEnvironmentStartInfo); 346var installRequirementsProcess = Process.Start(installRequirementsStartInfo);
Aspire.Hosting.RemoteHost (1)
OrphanDetector.cs (1)
26return !Process.GetProcessById(pid).HasExited;
Aspire.Hosting.Tests (6)
Cli\CliOrphanDetectorTests.cs (2)
238using var fakeCliProcess = Process.Start(psi);
MSBuildTests.cs (2)
226using var process = new Process(); 553using var process = new Process();
Utils\DockerUtils.cs (2)
19if (Process.Start("docker", $"volume rm {volumeName}") is { } process) 35if (Process.Start("docker", $"volume inspect {volumeName}") is { } process)
Aspire.Templates.Tests (5)
tests\Shared\TemplatesTesting\AspireProject.cs (1)
26public Process? AppHostProcess { get; private set; }
tests\Shared\TemplatesTesting\TestExtensions.cs (2)
20public static bool TryGetHasExited(this Process process) 32public static void CloseAndKillProcessIfRunning(this Process process)
tests\Shared\TemplatesTesting\ToolCommand.cs (2)
19public Process? CurrentProcess { get; private set; } 208private Process CreateProcess(string executable, string args)
csc (5)
src\roslyn\src\Compilers\CSharp\csc\Program.cs (1)
31using var logger = new CompilerServerLogger($"csc {Process.GetCurrentProcess().Id}");
src\roslyn\src\Compilers\Shared\BuildServerConnection.cs (3)
169using var process = Process.GetProcessById(serverProcessId); 651if (Process.Start(startInfo) is { } process)
src\roslyn\src\Compilers\Shared\CompilerServerLogger.cs (1)
125var processId = Process.GetCurrentProcess().Id;
datacollector (7)
src\vstest\src\Microsoft.TestPlatform.Execution.Shared\DebuggerBreakpoint.cs (7)
60ConsoleOutput.Instance.WriteLine($"Attaching Visual Studio with PID {vsPid} to the process '{Process.GetCurrentProcess().ProcessName}({processId})'...", OutputLevel.Information); 63AttachVs(Process.GetCurrentProcess(), vsPid); 69private static bool AttachVs(Process process, int? vsPid) 90var attachVsProcess = Process.Start(vsAttachPath, $"{process.Id} {vsPid}"); 132var currentProcess = Process.GetCurrentProcess();
datacollector.arm64 (7)
src\vstest\src\Microsoft.TestPlatform.Execution.Shared\DebuggerBreakpoint.cs (7)
60ConsoleOutput.Instance.WriteLine($"Attaching Visual Studio with PID {vsPid} to the process '{Process.GetCurrentProcess().ProcessName}({processId})'...", OutputLevel.Information); 63AttachVs(Process.GetCurrentProcess(), vsPid); 69private static bool AttachVs(Process process, int? vsPid) 90var attachVsProcess = Process.Start(vsAttachPath, $"{process.Id} {vsPid}"); 132var currentProcess = Process.GetCurrentProcess();
dotnet (17)
CommandFactory\CommandFactoryUsingResolver.cs (1)
118var _process = new Process
Commands\Clean\FileBasedAppArtifacts\CleanFileBasedAppArtifactsCommand.cs (1)
141Process.Start(startInfo);
Commands\Help\HelpCommand.cs (2)
45public static Process ConfigureProcess(string docUrl) 90var process = ConfigureProcess(docsLink);
Commands\Test\MTP\CtrlCCancellationManager.cs (5)
34private readonly ConcurrentDictionary<Process, byte> _processes = new(); 64public void Register(Process process) 76public void Unregister(Process process) 135foreach (var process in _processes.Keys) 144private static void TryKill(Process process)
Commands\Test\MTP\TestApplication.cs (2)
66Process? process = null; 71process = Process.Start(processStartInfo)!;
Program.cs (2)
64?.SetStartTime(Process.GetCurrentProcess().StartTime) 65?.AddTag("process.pid", Process.GetCurrentProcess().Id)
src\sdk\artifacts\.packages\microsoft.codeanalysis.buildclient\5.9.0-1.26325.102\contentFiles\cs\net11.0\BuildServerConnection.cs (3)
169using var process = Process.GetProcessById(serverProcessId); 651if (Process.Start(startInfo) is { } process)
src\sdk\artifacts\.packages\microsoft.codeanalysis.buildclient\5.9.0-1.26325.102\contentFiles\cs\net11.0\CompilerServerLogger.cs (1)
125var processId = Process.GetCurrentProcess().Id;
dotnet-dev-certs (14)
src\aspnetcore\src\Shared\CertificateGeneration\MacOSCertificateManager.cs (7)
106var exitStatus = Process.Run(new ProcessStartInfo(MacOSTrustCertificateCommandLine, MacOSTrustCertificateCommandLineArguments + tmpFile)); 170var checkTrustProcessOutput = Process.Run(checkTrustProcessStartInfo); 216var processExitStatus = Process.Run(processInfo); 257var processOutput = Process.RunAndCaptureText(processInfo); 284using var findCertificateProcess = Process.Start(new ProcessStartInfo( 354var processOutput = Process.RunAndCaptureText(processInfo);
src\aspnetcore\src\Shared\CertificateGeneration\UnixCertificateManager.cs (6)
696return Process.Run(startInfo).ExitCode == 0; 718return Process.Run(startInfo).ExitCode == 0; 746return Process.Run(startInfo).ExitCode == 0; 769if (Process.Run(startInfo).ExitCode == 0) 939var processOutput = Process.RunAndCaptureText(processInfo); 981var processOutput = Process.RunAndCaptureText(processInfo);
src\aspnetcore\src\Shared\CommandLineUtils\Utilities\DotNetMuxer.cs (1)
65var mainModuleFullPath = Process.GetCurrentProcess().MainModule?.FileName;
dotnet-format (8)
Utilities\ProcessRunner.cs (8)
11public Process Process { get; } 16public ProcessResult(Process process, int exitCode, ReadOnlyCollection<string> outputLines, ReadOnlyCollection<string> errorLines) 27public Process Process { get; } 33public ProcessInfo(Process process, ProcessStartInfo startInfo, Task<ProcessResult> result) 47Process.Start(file); 59Action<Process>? onProcessStartHandler = null, 70Action<Process>? onProcessStartHandler = null, 77var process = new Process();
dotnet-getdocument (3)
Exe.cs (2)
39using var process = Process.Start(startInfo);
src\aspnetcore\src\Shared\CommandLineUtils\Utilities\DotNetMuxer.cs (1)
65var mainModuleFullPath = Process.GetCurrentProcess().MainModule?.FileName;
dotnet-openapi (3)
Commands\BaseCommand.cs (2)
230using var process = Process.Start(startInfo);
src\aspnetcore\src\Shared\CommandLineUtils\Utilities\DotNetMuxer.cs (1)
65var mainModuleFullPath = Process.GetCurrentProcess().MainModule?.FileName;
dotnet-sql-cache (1)
src\aspnetcore\src\Shared\CommandLineUtils\Utilities\DotNetMuxer.cs (1)
65var mainModuleFullPath = Process.GetCurrentProcess().MainModule?.FileName;
dotnet-suggest (1)
SuggestionStore.cs (1)
38using (var process = new Process
dotnet-svcutil-lib (6)
Shared\Utilities\DebugUtils.cs (2)
42var process = Process.GetCurrentProcess();
Shared\Utilities\ProcessRunner.cs (2)
68using (var proc = new Process()) 150var exitCode = Path.GetFileName(processName) == Path.GetFileName(Process.GetCurrentProcess().MainModule.FileName) ? proc.ExitCode : -1;
Shared\Utilities\SafeLogger.cs (2)
25return $"[{Process.GetCurrentProcess().Id}.{startTime.Millisecond}] {message}"; 31return $"[{Process.GetCurrentProcess().Id}.{startTime.Millisecond}] Time elapsed: {DateTime.Now - startTime}";
dotnet-user-jwts (3)
src\aspnetcore\src\Shared\CommandLineUtils\Utilities\DotNetMuxer.cs (1)
65var mainModuleFullPath = Process.GetCurrentProcess().MainModule?.FileName;
src\aspnetcore\src\Tools\Shared\SecretsHelpers\ProjectIdResolver.cs (2)
84using var process = new Process() 168using var process = new Process()
dotnet-user-secrets (3)
src\aspnetcore\src\Shared\CommandLineUtils\Utilities\DotNetMuxer.cs (1)
65var mainModuleFullPath = Process.GetCurrentProcess().MainModule?.FileName;
src\aspnetcore\src\Tools\Shared\SecretsHelpers\ProjectIdResolver.cs (2)
84using var process = new Process() 168using var process = new Process()
GetDocument.Insider (1)
src\aspnetcore\src\Shared\CommandLineUtils\Utilities\DotNetMuxer.cs (1)
65var mainModuleFullPath = Process.GetCurrentProcess().MainModule?.FileName;
Infrastructure.Tests (8)
ExtractTestPartitions\ExtractTestPartitionsFixture.cs (1)
32using var process = new Process { StartInfo = psi };
ExtractTestPartitions\ExtractTestPartitionsTests.cs (1)
313using var process = new Process { StartInfo = psi };
PowerShellScripts\PowerShellCommand.cs (4)
22public Process? CurrentProcess { get; private set; } 199private Process CreateProcess(string args) 304public static bool TryGetHasExited(this Process process) 316public static void CloseAndKillProcessIfRunning(this Process? process)
WorkflowScripts\NodeCommand.cs (2)
27public Process? CurrentProcess { get; private set; } 179private Process CreateProcess(string scriptPath, string[] args)
Microsoft.Agents.AI.ProjectTemplates.Tests (2)
test\ProjectTemplates\Infrastructure\ProcessExtensions.cs (1)
11public static bool TryGetHasExited(this Process process)
test\ProjectTemplates\Infrastructure\TestCommand.cs (1)
55using var process = new Process
Microsoft.Arcade.Common (1)
Command.cs (1)
18private readonly Process _process;
Microsoft.AspNetCore.Components.Testing (4)
Infrastructure\ParentProcessWatcher.cs (2)
33var parent = Process.GetProcessById(_parentPid);
Infrastructure\ServerInstance.cs (2)
27private Process? _process; 130_process = Process.Start(startInfo)
Microsoft.AspNetCore.Components.WebAssembly.Server (5)
DebugProxyLauncher.cs (4)
77var debugProxyProcess = Process.Start(processStartInfo); 139private static void PassThroughConsoleOutput(Process process) 165private static void CompleteTaskWhenServerIsReady(Process aspNetProcess, bool isFirefox, TaskCompletionSource<string> taskCompletionSource)
src\aspnetcore\src\Shared\CommandLineUtils\Utilities\DotNetMuxer.cs (1)
65var mainModuleFullPath = Process.GetCurrentProcess().MainModule?.FileName;
Microsoft.AspNetCore.Components.WebView.WindowsForms (1)
src\BlazorWebView\src\SharedSource\WebView2WebViewManager.cs (1)
381 using (var launchBrowser = new Process())
Microsoft.AspNetCore.Components.WebView.Wpf (1)
src\BlazorWebView\src\SharedSource\WebView2WebViewManager.cs (1)
381 using (var launchBrowser = new Process())
Microsoft.AspNetCore.DeveloperCertificates.XPlat (13)
src\aspnetcore\src\Shared\CertificateGeneration\MacOSCertificateManager.cs (7)
106var exitStatus = Process.Run(new ProcessStartInfo(MacOSTrustCertificateCommandLine, MacOSTrustCertificateCommandLineArguments + tmpFile)); 170var checkTrustProcessOutput = Process.Run(checkTrustProcessStartInfo); 216var processExitStatus = Process.Run(processInfo); 257var processOutput = Process.RunAndCaptureText(processInfo); 284using var findCertificateProcess = Process.Start(new ProcessStartInfo( 354var processOutput = Process.RunAndCaptureText(processInfo);
src\aspnetcore\src\Shared\CertificateGeneration\UnixCertificateManager.cs (6)
696return Process.Run(startInfo).ExitCode == 0; 718return Process.Run(startInfo).ExitCode == 0; 746return Process.Run(startInfo).ExitCode == 0; 769if (Process.Run(startInfo).ExitCode == 0) 939var processOutput = Process.RunAndCaptureText(processInfo); 981var processOutput = Process.RunAndCaptureText(processInfo);
Microsoft.AspNetCore.InternalTesting (4)
CollectDumpAttribute.cs (2)
31var process = Process.GetCurrentProcess();
DumpCollector\DumpCollector.cs (1)
11public static void Collect(Process process, string fileName)
DumpCollector\DumpCollector.Windows.cs (1)
16internal static void Collect(Process process, string outputFile)
Microsoft.AspNetCore.Server.IntegrationTesting (17)
ApplicationPublisher.cs (1)
64var hostProcess = new Process() { StartInfo = startInfo };
Common\ProcessLoggingExtensions.cs (1)
10public static void StartAndCaptureOutAndErrToLogger(this Process process, string prefix, ILogger logger)
Deployers\ApplicationDeployer.cs (1)
115protected void ShutDownIfAnyHostProcess(Process hostProcess)
Deployers\NginxDeployer.cs (3)
114using (var process = new Process 169using (var runNginx = new Process() { StartInfo = startInfo }) 211using (var runNginx = new Process() { StartInfo = startInfo })
Deployers\RemoteWindowsDeployer\RemoteWindowsDeployer.cs (1)
247using (var runScriptsOnRemoteServerProcess = new Process() { StartInfo = startInfo })
Deployers\SelfHostDeployer.cs (1)
20public Process HostProcess { get; private set; }
src\aspnetcore\src\Shared\Process\ProcessEx.cs (5)
25private readonly Process _process; 36public ProcessEx(ITestOutputHelper output, Process proc, TimeSpan timeout) 69public Process Process => _process; 130var proc = Process.Start(startInfo);
src\aspnetcore\src\Shared\Process\ProcessExtensions.cs (4)
16public static void KillTree(this Process process) => process.KillTree(_defaultTimeout); 18public static void KillTree(this Process process, TimeSpan timeout) 106var process = Process.Start(startInfo);
Microsoft.AspNetCore.Server.Kestrel.Core (13)
src\aspnetcore\src\Shared\CertificateGeneration\MacOSCertificateManager.cs (7)
106var exitStatus = Process.Run(new ProcessStartInfo(MacOSTrustCertificateCommandLine, MacOSTrustCertificateCommandLineArguments + tmpFile)); 170var checkTrustProcessOutput = Process.Run(checkTrustProcessStartInfo); 216var processExitStatus = Process.Run(processInfo); 257var processOutput = Process.RunAndCaptureText(processInfo); 284using var findCertificateProcess = Process.Start(new ProcessStartInfo( 354var processOutput = Process.RunAndCaptureText(processInfo);
src\aspnetcore\src\Shared\CertificateGeneration\UnixCertificateManager.cs (6)
696return Process.Run(startInfo).ExitCode == 0; 718return Process.Run(startInfo).ExitCode == 0; 746return Process.Run(startInfo).ExitCode == 0; 769if (Process.Run(startInfo).ExitCode == 0) 939var processOutput = Process.RunAndCaptureText(processInfo); 981var processOutput = Process.RunAndCaptureText(processInfo);
Microsoft.AspNetCore.SpaProxy (6)
SpaProxyLaunchManager.cs (6)
19private Process? _spaProcess; 199_spaProcess = Process.Start(info); 246var stopProcess = Process.Start(stopScriptInfo); 308var stopProcess = Process.Start(stopScriptInfo);
Microsoft.AspNetCore.SpaServices.Extensions (4)
Npm\NodeScriptRunner.cs (4)
19private Process? _npmProcess; 123private static Process LaunchNodeProcess(ProcessStartInfo startInfo, string commandName) 127var process = Process.Start(startInfo)!;
Microsoft.Build (57)
BackEnd\BuildManager\BuildManager.cs (6)
483private void UpdatePriority(Process p, ProcessPriorityClass priority) 511IEnumerable<Process>? processes = _nodeManager?.GetProcesses(); 514foreach (Process p in processes) 523foreach (Process p in processes) 918/// <returns>Enumeration of <see cref="Process"/> objects that were valid during the time of call to this function.</returns> 919public IEnumerable<Process> GetWorkerProcesses()
BackEnd\BuildManager\CoordinatorClient.cs (2)
533Process? process = Process.Start(startInfo);
BackEnd\Client\MSBuildClient.cs (3)
531using Process msbuildProcess = nodeLauncher.Start(launchData, nodeId: 0); 749using Process launched = Process.GetProcessById(pid);
BackEnd\Components\Communications\INodeLauncher.cs (1)
38Process Start(NodeLaunchData launchData, int nodeId);
BackEnd\Components\Communications\INodeManager.cs (1)
56IEnumerable<Process> GetProcesses();
BackEnd\Components\Communications\INodeProvider.cs (1)
91IEnumerable<Process> GetProcesses();
BackEnd\Components\Communications\NodeLauncher.cs (7)
50public Process Start(NodeLaunchData launchData, int nodeId) 60private Process StartInternal(NodeLaunchData nodeLaunchData) 114private Process StartProcessUnix(NodeLaunchData nodeLaunchData, string exeName, bool redirectStreams, bool isNativeAppHost) 137Process process = Process.Start(processStartInfo); 326private static Process DisableMSBuildServer(Func<Process> func)
BackEnd\Components\Communications\NodeManager.cs (1)
350public IEnumerable<Process> GetProcesses()
BackEnd\Components\Communications\NodeProviderInProc.cs (1)
469public IEnumerable<Process> GetProcesses() => throw new NotImplementedException();
BackEnd\Components\Communications\NodeProviderOutOfProc.cs (1)
212public IEnumerable<Process> GetProcesses()
BackEnd\Components\Communications\NodeProviderOutOfProcBase.cs (27)
166List<Process> nodeProcesses = GetPossibleRunningNodes().nodeProcesses.ToList(); 172nodeProcesses.AddRange(Process.GetProcessesByName(Path.GetFileNameWithoutExtension(msbuildtaskhostExeName))); 175foreach (Process nodeProcess in nodeProcesses) 266ConcurrentQueue<Process> possibleRunningNodes = null; 271IList<Process> possibleRunningNodesList; 275possibleRunningNodes = new ConcurrentQueue<Process>(possibleRunningNodesList); 320while (possibleRunningNodes != null && possibleRunningNodes.TryDequeue(out var nodeToReuse)) 393Process msbuildProcess = nodeLauncher.Start(launchData, nodeId); 441void CreateNodeContext(int nodeId, Process nodeToReuse, Stream nodeStream, byte negotiatedVersion) 458private (string expectedProcessName, IList<Process> nodeProcesses) GetPossibleRunningNodes( 472List<Process> processes = new(); 477processes.AddRange(Process.GetProcessesByName(name)); 578private static IList<Process> FilterProcessesByNodeMode(List<Process> processes, NodeMode expectedNodeMode, string expectedProcessName) 582List<Process> filtered = new(capacity: processes.Count); 584foreach (Process process in processes) 725(_, IList<Process> nodeProcesses) = GetPossibleRunningNodes(nodeMode); 727foreach (var process in nodeProcesses) 740private static (string expectedProcessName, IList<Process> nodeProcesses) GetPossibleRunningNodes(NodeMode? expectedNodeMode) 744Process[] processes; 747processes = Process.GetProcessesByName(expectedProcessName); 751return (expectedProcessName, Array.Empty<Process>()); 756List<Process> filteredProcesses = []; 758foreach (var process in processes) 943private readonly Process _process; 945internal Process Process { get { return _process; } } 1025Process process,
BackEnd\Components\Communications\NodeProviderOutOfProcTaskHost.cs (1)
904public IEnumerable<Process> GetProcesses() => _nodeContexts.Values.Select(context => context.Process);
BackEnd\Components\Communications\TaskHostNodeManager.cs (1)
182IEnumerable<Process> INodeManager.GetProcesses()
BackEnd\Node\OutOfProcNode.cs (2)
872using Process currentProcess = Process.GetCurrentProcess();
Evaluation\ProjectRootElementCache.cs (1)
667Trace.WriteLine($"{prefix} {Process.GetCurrentProcess().Id} | {message}{param1}");
Instance\TaskFactories\TaskHostTask.cs (1)
389Process.GetCurrentProcess().Id,
Microsoft.Build.Framework (12)
BackEnd\Handshake.cs (2)
96using var currentProcess = Process.GetCurrentProcess();
EnvironmentUtilities.cs (2)
90using Process currentProcess = Process.GetCurrentProcess();
Telemetry\CrashTelemetry.cs (4)
456using var process = System.Diagnostics.Process.GetCurrentProcess(); 480using var process = System.Diagnostics.Process.GetCurrentProcess();
Utilities\ProcessExtensions.cs (4)
31public static void KillTree(this Process process, int timeoutMilliseconds) 70public static bool TryGetCommandLine(this Process? process, out string? commandLine) 91public static bool TryGetCommandLine(this Process? process, CommandLineSource source, out string? commandLine) 219/// Do not attempt to retrieve the command line. Default behavior; <see cref="TryGetCommandLine(Process?, out string?)"/>
Microsoft.Build.Tasks.CodeAnalysis (5)
src\roslyn\src\Compilers\Core\MSBuildTask\ManagedCompiler.cs (1)
509using var innerLogger = new CompilerServerLogger($"MSBuild {Process.GetCurrentProcess().Id}");
src\roslyn\src\Compilers\Shared\BuildServerConnection.cs (3)
169using var process = Process.GetProcessById(serverProcessId); 651if (Process.Start(startInfo) is { } process)
src\roslyn\src\Compilers\Shared\CompilerServerLogger.cs (1)
125var processId = Process.GetCurrentProcess().Id;
Microsoft.Build.Tasks.Core (2)
ManifestUtil\SecurityUtil.cs (2)
817Process signTool = null; 821signTool = Process.Start(startInfo);
Microsoft.Build.Utilities.Core (10)
ToolTask.cs (10)
365/// Overridable function called after <see cref="Process.Start()"/> in <see cref="ExecuteTool"/> 734/// <param name="proc">Fully populated <see cref="Process"/> instance representing the tool process to be started.</param> 735/// <returns>A started process. This could be <paramref name="proc"/> or another <see cref="Process"/> instance.</returns> 736protected virtual Process StartToolProcess(Process proc) 761Process proc = null; 935private void HandleToolNotifications(Process proc) 1034private void KillToolProcessOnTimeout(Process proc, bool isBeingCancelled) 1077private void TerminateToolProcess(Process proc, bool isBeingCancelled) 1115private void WaitForProcessExit(Process proc)
Microsoft.CodeAnalysis.VisualBasic (1)
CommandLine\VisualBasicCommandLineParser.vb (1)
458Dim processId = System.Diagnostics.Process.GetCurrentProcess().Id
Microsoft.CodeAnalysis.Workspaces (1)
Workspace\Host\PersistentStorage\IPersistentStorageConfiguration.cs (1)
52var fileName = Process.GetCurrentProcess().MainModule?.FileName;
Microsoft.CodeAnalysis.Workspaces.MSBuild (4)
MSBuild\BuildHostProcessManager.cs (4)
120var process = Process.Start(processStartInfo); 428private readonly Process _process; 440public BuildHostProcess(Process process, ILoggerFactory? loggerFactory)
Microsoft.Data.Analysis.Tests (2)
test\Microsoft.ML.TestFramework\BaseTestClass.cs (2)
81Process proc = Process.GetCurrentProcess();
Microsoft.Diagnostics.NETCore.Client (3)
DiagnosticsIpc\IpcTransport.cs (1)
488Process.GetProcessById(pid);
DiagnosticsServerRouter\DiagnosticsServerRouterFactory.cs (2)
428_tcpClientAddress = IpcTcpSocketEndPoint.NormalizeTcpIpEndPoint(string.IsNullOrEmpty(tcpClient) ? "127.0.0.1:" + string.Format("{0}", 56000 + (Process.GetCurrentProcess().Id % 1000)) : tcpClient); 1432_runtimeProcessId = (ulong)Process.GetCurrentProcess().Id;
Microsoft.DotNet.Arcade.Sdk (2)
src\InstallDotNetCore.cs (2)
157var process = Process.Start(new ProcessStartInfo()
Microsoft.DotNet.Cli.Utils (10)
Command.cs (3)
8public class Command(Process? process, bool trimTrailingNewlines = false, IDictionary<string, string?>? customEnvironmentVariables = null) : ICommand 10private readonly Process _process = process ?? throw new ArgumentNullException(nameof(process)); 28public CommandResult Execute(Action<Process>? processStarted)
Extensions\ProcessStartInfoExtensions.cs (2)
14var process = new Process 37var process = new Process
ProcessReaper.cs (5)
30private readonly Process _process; 132public UnixProcessReaper(Process process) : base(process) 185/// <inheritdoc cref="ProcessReaper(Process)"/> 186public static ProcessReaper Create(Process process) 201private ProcessReaper(Process process)
Microsoft.DotNet.HotReload.Watch (14)
Browser\BrowserLauncher.cs (1)
100using var browserProcess = ProcessRunner.TryStartProcess(processSpec, logger);
Process\ProcessRunner.cs (9)
13private sealed class ProcessState(Process process) : IDisposable 15public Process Process { get; } = process; 137internal static Process? TryStartProcess(ProcessSpec processSpec, ILogger logger) 144var process = new Process 235private async ValueTask TerminateProcessAsync(Process process, ProcessSpec processSpec, ProcessState state, ILogger logger) 258private static async ValueTask<bool> WaitForExitAsync(Process process, ProcessState state, TimeSpan? timeout, ILogger logger) 321private static void TerminateProcess(Process process, ProcessState state, ILogger logger, bool force) 343private static void TerminateWindowsProcess(Process process, ProcessState state, ILogger logger, bool force) 370private static void TerminateUnixProcess(Process process, ProcessState state, ILogger logger, bool force)
src\sdk\src\Dotnet.Watch\HotReloadClient\Web\KestrelWebSocketServer.cs (2)
102using var process = Process.Start(dotnetPath, "dev-certs https --check --quiet");
UI\PhysicalConsole.cs (2)
64using var process = Process.GetProcessById(processId);
Microsoft.DotNet.MacOsPkg.Core (1)
ExecuteHelper.cs (1)
23using (Process process = new Process { StartInfo = processStartInfo })
Microsoft.DotNet.StrongName (4)
Signing.cs (2)
116var process = Process.Start(new ProcessStartInfo()
Verification.cs (2)
152var process = Process.Start(new ProcessStartInfo()
Microsoft.Extensions.AI.Evaluation.Console (1)
Commands\ReportCommand.cs (1)
151_ = Process.Start(
Microsoft.Extensions.AI.Templates.Tests (2)
test\ProjectTemplates\Infrastructure\ProcessExtensions.cs (1)
11public static bool TryGetHasExited(this Process process)
test\ProjectTemplates\Infrastructure\TestCommand.cs (1)
55using var process = new Process
Microsoft.Extensions.DataIngestion.MarkItDown (1)
MarkItDownReader.cs (1)
75using (Process process = new() { StartInfo = startInfo })
Microsoft.Extensions.DataIngestion.Tests (1)
Readers\MarkItDownConditionAttribute.cs (1)
36using Process process = new() { StartInfo = startInfo };
Microsoft.Extensions.Diagnostics.ResourceMonitoring (2)
Windows\Interop\ProcessInfo.cs (2)
16foreach (var process in Process.GetProcesses())
Microsoft.Extensions.Hosting.WindowsServices (3)
Internal\Win32.cs (2)
14internal static unsafe Process? GetParentProcess() 31return Process.GetProcessById(procEntry.th32ParentProcessID);
WindowsServiceHelpers.cs (1)
41var parent = Internal.Win32.GetParentProcess();
Microsoft.Extensions.Telemetry (1)
Enrichment\StaticProcessLogEnricher.cs (1)
27var pid = System.Diagnostics.Process.GetCurrentProcess().Id;
Microsoft.Extensions.Telemetry.Tests (1)
Enrichment\ProcessLogEnricherTests.cs (1)
17private readonly int _processId = System.Diagnostics.Process.GetCurrentProcess().Id;
Microsoft.McpServer.ProjectTemplates.Tests (2)
test\ProjectTemplates\Infrastructure\ProcessExtensions.cs (1)
11public static bool TryGetHasExited(this Process process)
test\ProjectTemplates\Infrastructure\TestCommand.cs (1)
55using var process = new Process
Microsoft.ML.AutoML (4)
AutoMLExperiment\IPerformanceMonitor.cs (4)
81_totalCpuProcessorTime = Process.GetCurrentProcess().TotalProcessorTime; 120using (var process = Process.GetCurrentProcess()) 122var currentCpuProcessorTime = Process.GetCurrentProcess().TotalProcessorTime;
Microsoft.ML.CodeGenerator (3)
Utils.cs (3)
195var proc = new System.Diagnostics.Process(); 221var proc = new System.Diagnostics.Process(); 242var proc = new System.Diagnostics.Process();
Microsoft.ML.Data (2)
Utilities\TimerScope.cs (2)
36long physicalMemoryUsageInMB = System.Diagnostics.Process.GetCurrentProcess().PeakWorkingSet64 / 1024 / 1024; 39long virtualMemoryUsageInMB = System.Diagnostics.Process.GetCurrentProcess().PeakVirtualMemorySize64 / 1024 / 1024;
Microsoft.ML.FastTree (3)
FastTree.cs (2)
452Process currentProcess = Process.GetCurrentProcess();
GamModelParameters.cs (1)
956System.Diagnostics.Process.Start(uri.AbsoluteUri + "content/GamViz/");
Microsoft.ML.Sweeper (1)
ConfigRunner.cs (1)
226var p = new System.Diagnostics.Process
Microsoft.ML.TestFramework (3)
BaseTestClass.cs (2)
81Process proc = Process.GetCurrentProcess();
CopyAction.cs (1)
47if (System.Diagnostics.Process.GetCurrentProcess().ProcessName == "dotnet")
Microsoft.NET.Build.Containers (5)
LocalDaemons\DockerCli.cs (5)
106using Process? loadProcess = Process.Start(loadInfo) ?? 294Process proc = new() 776using Process process = Process.Start(psi) ??
Microsoft.NET.HostModel (2)
HostModelUtils.cs (2)
34using (var p = Process.Start(psi))
Microsoft.NET.Sdk.Publish.Tasks (2)
Tasks\GenerateEFSQLScripts.cs (2)
79private Process? _runningProcess; 97Process? proc = null;
Microsoft.NET.Sdk.Razor.Tasks (2)
src\sdk\src\RazorSdk\Tool\ServerProtocol\ServerConnection.cs (2)
399var process = Process.Start(startInfo);
Microsoft.TemplateEngine.Cli (5)
IReporterExtensions.cs (1)
28internal static void WriteCommandOutput(this IReporter reporter, Process process)
PostActionProcessors\ChmodPostActionProcessor.cs (2)
42Process? commandResult = System.Diagnostics.Process.Start(new ProcessStartInfo
PostActionProcessors\ProcessStartPostActionProcessor.cs (2)
53Process? commandResult = System.Diagnostics.Process.Start(new ProcessStartInfo
Microsoft.TestPlatform.Build (4)
Tasks\VSTestTask.cs (4)
56var currentProcess = Process.GetCurrentProcess(); 87using var activeProcess = new Process { StartInfo = processInfo }; 101Process.GetProcessById(_activeProcessId).Kill();
Microsoft.TestPlatform.CrossPlatEngine (1)
EventHandlers\TestRequestHandler.cs (1)
112var currentProcessPath = Process.GetCurrentProcess().MainModule?.FileName;
Microsoft.TestPlatform.Extensions.BlameDataCollector (43)
BlameCollector.cs (2)
311var p = Process.GetProcessById(_testHostProcessId);
MiniDumpWriteDump.cs (1)
25public static void CollectDumpUsingMiniDumpWriteDump(Process process, string outputFile, MiniDumpTypeOption type)
NetClientHangDumper.cs (4)
22var process = Process.GetProcessById(processId); 59foreach (var p in bottomUpTree) 92foreach (var p in bottomUpTree)
ProcDumpDumper.cs (8)
37private Process? _procDumpProcess; 42private Process? _process; 118_process = Process.GetProcessById(processId); 148_procDumpProcess = (Process)_processHelper.LaunchProcess( 291var process = Process.GetProcessById(processId); 318var procDumpProcess = (Process)_processHelper.LaunchProcess(
ProcessCodeMethods.cs (12)
24public static void Suspend(this Process process) 44public static List<ProcessTreeNode> GetProcessTree(this Process process) 46var childProcesses = Process.GetProcesses() 51foreach (var c in childProcesses) 79internal static int GetParentPid(Process process) 90internal static int GetParentPidWindows(Process process) 111internal static int GetParentPidLinux(Process process) 133internal static int GetParentPidMacOs(Process process) 139Process ps = new(); 167private static void ResolveChildren(Process parent, List<ProcessTreeNode> acc, int level, int limit) 185private static bool IsChildCandidate(Process child, Process parent)
ProcessTreeNode.cs (2)
10public Process? Process { get; set; } 16public Process? ParentProcess { get; set; }
src\vstest\src\Microsoft.TestPlatform.Execution.Shared\DebuggerBreakpoint.cs (7)
60ConsoleOutput.Instance.WriteLine($"Attaching Visual Studio with PID {vsPid} to the process '{Process.GetCurrentProcess().ProcessName}({processId})'...", OutputLevel.Information); 63AttachVs(Process.GetCurrentProcess(), vsPid); 69private static bool AttachVs(Process process, int? vsPid) 90var attachVsProcess = Process.Start(vsAttachPath, $"{process.Id} {vsPid}"); 132var currentProcess = Process.GetCurrentProcess();
WindowsHangDumper.cs (7)
40var process = Process.GetProcessById(processId); 69foreach (var p in bottomUpTree) 83foreach (var p in bottomUpTree) 109internal static void CollectDump(IProcessHelper processHelper, Process process, string outputFile, DumpTypeOption type) 153var dumpMiniTool = (Process)new ProcessHelper().LaunchProcess(
Microsoft.TestPlatform.PlatformAbstractions (23)
common\System\ProcessHelper.cs (14)
24private readonly Process _currentProcess = Process.GetCurrentProcess(); 63var process = new Process(); 127process.OutputDataReceived += (sender, args) => outputCallBack(sender as Process, args.Data); 132process.ErrorDataReceived += (sender, args) => errorCallback(sender as Process, args.Data); 141if (sender is Process p) 255return Process.GetProcessById(processId).ProcessName; 263if (process is Process proc && proc.HasExited) 283var process = processId == _currentProcess.Id ? _currentProcess : Process.GetProcessById(processId); 300if (process is Process proc && !proc.HasExited) 314var proc = process as Process; 336if (process is Process proc && !proc.HasExited)
common\Tracing\PlatformEqtTrace.cs (6)
337using var process = Process.GetCurrentProcess(); 408using var process = Process.GetCurrentProcess(); 427using var process = Process.GetCurrentProcess();
net462\System\ProcessHelper.cs (2)
64var process = processId == _currentProcess.Id ? _currentProcess : Process.GetProcessById(processId);
netcore\System\ProcessHelper.cs (1)
29return Process.GetProcessById(processId).SafeHandle.DangerousGetHandle();
Microsoft.TestPlatform.TestHostRuntimeProvider (8)
Hosting\DefaultTestHostManager.cs (4)
65private Process? _testHostProcess; 553_createNoNewWindow) as Process; 558_testHostProcess = Process.GetProcessById(processId); 573internal static void AdjustProcessPriorityBasedOnSettings(Process testHostProcess, IDictionary<string, string?>? testHostEnvironmentVariables)
Hosting\DotnetTestHostManager.cs (3)
73private Process? _testHostProcess; 869_createNoNewWindow) as Process; 874_testHostProcess = Process.GetProcessById(processId);
Hosting\TestHostManagerCallbacks.cs (1)
90if (process is Process p)
Microsoft.TestPlatform.VsTestConsole.TranslationLayer (3)
VsTestConsoleProcessManager.cs (3)
58private Process? _process; 167_process = Process.Start(info); 241ExitCode = ((Process)sender!).ExitCode;
MSBuild (4)
XMake.cs (4)
532using Process currentProcess = Process.GetCurrentProcess(); 2267using Process currentProcess = Process.GetCurrentProcess();
MSBuild.Coordinator (2)
CoordinatorServer.cs (2)
381using Process process = Process.GetProcessById(processId);
netstandard (1)
netstandard.cs (1)
665[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Diagnostics.Process))]
NuGet.Build.Tasks (1)
StaticGraphRestoreTaskBase.cs (1)
117using (var process = new Process())
NuGet.CommandLine.XPlat (2)
Commands\Package\Update\PackageUpdateIO.cs (2)
122using var process = Process.Start(processStartInfo);
NuGet.Common (3)
Migrations\Migration1.cs (1)
201using (var proc = new Process())
RuntimeEnvironmentHelper.cs (2)
62using (var process = Process.GetCurrentProcess())
NuGet.Credentials (3)
PluginCredentialProvider.cs (3)
257using var process = Process.Start(startInfo); 310private static void Kill(Process p)
NuGet.PackageManagement (1)
Utility\UriHelper.cs (1)
44Process.Start(url.AbsoluteUri);
NuGet.Packaging (1)
NuGetExtractionFileIO.cs (1)
108using (var process = new Process())
NuGet.Protocol (13)
Plugins\Logging\PluginLogger.cs (2)
103using (var process = Process.GetCurrentProcess())
Plugins\Logging\ProcessLogMessage.cs (2)
20using (var process = Process.GetCurrentProcess())
Plugins\PluginManager.cs (2)
386using (var process = Process.GetCurrentProcess())
Plugins\PluginProcess.cs (3)
19private readonly Process _process; 70_process = Process.GetCurrentProcess(); 170if (sender is Process process)
Plugins\RequestHandlers\MonitorNuGetProcessExitRequestHandler.cs (4)
22private readonly ConcurrentDictionary<int, Process> _processes; 39_processes = new ConcurrentDictionary<int, Process>(); 103Process? process = null; 107process = _processes.GetOrAdd(monitorRequest.ProcessId, pid => Process.GetProcessById(pid));
Pipelines.AppHost (8)
AppHost.cs (8)
74var getUserProcess = System.Diagnostics.Process.Start(new System.Diagnostics.ProcessStartInfo 109var getSubscriptionProcess = System.Diagnostics.Process.Start(new System.Diagnostics.ProcessStartInfo 144var getResourceGroupProcess = System.Diagnostics.Process.Start(new System.Diagnostics.ProcessStartInfo 182var assignRoleProcess = System.Diagnostics.Process.Start(new System.Diagnostics.ProcessStartInfo
Pipelines.Library (2)
DistributedApplicationPipelineExtensions.cs (2)
74var publishProcess = Process.Start(new ProcessStartInfo
PresentationUI (4)
InstallationError.xaml.cs (1)
211Process Notepad = new Process();
MS\Internal\Documents\RightsManagementProvider.cs (2)
1341System.Diagnostics.Process currentProcess = System.Diagnostics.Process.GetCurrentProcess();
TenFeetInstallationError.xaml.cs (1)
215Process Notepad = new Process();
RepoTasks (13)
src\aspnetcore\src\Shared\CertificateGeneration\MacOSCertificateManager.cs (7)
106var exitStatus = Process.Run(new ProcessStartInfo(MacOSTrustCertificateCommandLine, MacOSTrustCertificateCommandLineArguments + tmpFile)); 170var checkTrustProcessOutput = Process.Run(checkTrustProcessStartInfo); 216var processExitStatus = Process.Run(processInfo); 257var processOutput = Process.RunAndCaptureText(processInfo); 284using var findCertificateProcess = Process.Start(new ProcessStartInfo( 354var processOutput = Process.RunAndCaptureText(processInfo);
src\aspnetcore\src\Shared\CertificateGeneration\UnixCertificateManager.cs (6)
696return Process.Run(startInfo).ExitCode == 0; 718return Process.Run(startInfo).ExitCode == 0; 746return Process.Run(startInfo).ExitCode == 0; 769if (Process.Run(startInfo).ExitCode == 0) 939var processOutput = Process.RunAndCaptureText(processInfo); 981var processOutput = Process.RunAndCaptureText(processInfo);
rzc (4)
ServerProtocol\ServerConnection.cs (2)
399var process = Process.Start(startInfo);
ShutdownCommand.cs (2)
59var process = Process.GetProcessById(response.ServerProcessId);
Stress.TelemetryService (4)
GaugeMetrics.cs (4)
15var process = Process.GetCurrentProcess(); 23var processes = Process.GetProcesses().ToList(); 25foreach (var process in processes)
SuperFileCheck (2)
Program.cs (2)
115using (var proc = Process.Start(startInfo))
System (1)
src\runtime\src\libraries\shims\System\ref\System.cs (1)
520[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Diagnostics.Process))]
System.CodeDom (2)
System\CodeDom\Compiler\Executor.cs (2)
67using (Process p = Process.Start(psi))
System.Configuration.ConfigurationManager (2)
System\Configuration\ClientConfigPaths.cs (2)
75using (Process currentProcess = Process.GetCurrentProcess())
System.Diagnostics.PerformanceCounter (2)
System\Diagnostics\PerformanceCounterLib.cs (2)
1195Process p; 1212p = Process.Start(processStartInfo);
System.Diagnostics.Process (85)
Microsoft\Win32\SafeHandles\SafeProcessHandle.cs (7)
69/// This API opens the handle immediately. In contrast, <see cref="Process.GetProcessById(int)"/> only checks whether 70/// the process is currently running; opening the process handle is deferred until <see cref="Process.SafeHandle"/> is accessed. 73/// On Windows, this API requests query/synchronize/terminate rights, while <see cref="Process.SafeHandle"/> requests 111/// This API opens the handle immediately. In contrast, <see cref="Process.TryGetProcessById(int, out Process)"/> only checks 112/// whether the process is currently running; opening the process handle is deferred until <see cref="Process.SafeHandle"/> is accessed. 115/// On Windows, this API requests query/synchronize/terminate rights, while <see cref="Process.SafeHandle"/> requests
Microsoft\Win32\SafeHandles\SafeProcessHandle.Unix.cs (1)
309filename = Process.GetPathToOpenFile();
System\Diagnostics\Process.cs (46)
91/// Initializes a new instance of the <see cref='System.Diagnostics.Process'/> class. 100if (GetType() == typeof(Process)) 468/// Gets or sets the properties to pass into the <see cref='System.Diagnostics.Process.Start(System.Diagnostics.ProcessStartInfo)'/> method for the <see cref='System.Diagnostics.Process'/>. 547/// Gets or sets whether the <see cref='System.Diagnostics.Process.Exited'/> 722/// Causes the <see cref="Process"/> component to wait the specified <paramref name="timeout"/> for the associated process to enter an idle state. 740/// No process is associated with this <see cref="Process"/> object. 907/// Returns a new <see cref='System.Diagnostics.Process'/> component given a process identifier and 911public static Process GetProcessById(int processId, string machineName) 924/// Returns a new <see cref='System.Diagnostics.Process'/> component given the 928public static Process GetProcessById(int processId) 940/// Attempts to get a <see cref="Process"/> instance for an existing process with the specified process ID. 943/// <param name="process">When this method returns <see langword="true"/>, contains a <see cref="Process"/> representing the opened process; otherwise, <see langword="null"/>.</param> 949public static bool TryGetProcessById(int processId, [NotNullWhen(true)] out Process? process) 966/// Creates an array of <see cref='System.Diagnostics.Process'/> components that are 975public static Process[] GetProcessesByName(string? processName) 985/// Creates an array of <see cref="Process"/> components that are associated with process resources on a 991public static Process[] GetProcessesByName(string? processName, string machineName) 1002/// Creates a new <see cref='System.Diagnostics.Process'/> 1009public static Process[] GetProcesses() 1019/// Creates a new <see cref='System.Diagnostics.Process'/> 1027public static Process[] GetProcesses(string machineName) 1035private static Process[] CreateProcessArray(ArrayBuilder<ProcessInfo> processInfos, string machineName, bool isRemoteMachine) 1039Process[] processes = new Process[processInfos.Count]; 1052/// Returns a new <see cref='System.Diagnostics.Process'/> 1056public static Process GetCurrentProcess() 1063/// Raises the <see cref='System.Diagnostics.Process.Exited'/> event. 1104/// that has been cached inside the process component. After <see cref='System.Diagnostics.Process.Refresh'/> is called, the 1175/// Starts a process specified by the <see cref='System.Diagnostics.Process.StartInfo'/> property of this <see cref='System.Diagnostics.Process'/> 1177/// <see cref='System.Diagnostics.Process'/> . If a process resource is reused 1178/// rather than started, the reused process is associated with this <see cref='System.Diagnostics.Process'/> 1346/// document or application file. Associates the process resource with a new <see cref='System.Diagnostics.Process'/> 1353public static Process Start(string fileName) 1365/// with a new <see cref='System.Diagnostics.Process'/> 1372public static Process Start(string fileName, string? arguments) 1386public static Process Start(string fileName, IEnumerable<string> arguments) 1395/// Associates the process resource with a new <see cref='System.Diagnostics.Process'/> 1402public static Process? Start(ProcessStartInfo startInfo) 1406Process process = new Process(); 1470/// Instructs the <see cref='System.Diagnostics.Process'/> component to wait 1625/// Instructs the <see cref='System.Diagnostics.Process'/> component to start 1662/// Instructs the <see cref='System.Diagnostics.Process'/> component to start 1701/// Instructs the <see cref='System.Diagnostics.Process'/> component to cancel the asynchronous operation 1722/// Instructs the <see cref='System.Diagnostics.Process'/> component to cancel the asynchronous operation
System\Diagnostics\Process.Linux.cs (2)
88/// It is the sum of the <see cref='System.Diagnostics.Process.UserProcessorTime'/> and 89/// <see cref='System.Diagnostics.Process.PrivilegedProcessorTime'/>.
System\Diagnostics\Process.NonUap.cs (11)
35private bool IsSelfOrDescendantOf(Process processOfInterest) 40Process[] allProcesses = GetProcesses(); 44var descendantProcesses = new Queue<Process>(); 45Process? current = this; 49foreach (Process candidate in current.GetChildProcesses(allProcesses)) 60foreach (Process process in allProcesses) 72private List<Process> GetChildProcesses(Process[]? processes = null) 77List<Process> childProcesses = new List<Process>(); 79foreach (Process possibleChildProcess in processes)
System\Diagnostics\Process.Scenarios.cs (2)
243using Process process = Start(startInfo)!; 321using Process process = Start(startInfo)!;
System\Diagnostics\Process.Unix.cs (6)
39public static Process Start(string fileName, string userName, SecureString password, string domain) 46public static Process Start(string fileName, string arguments, string userName, SecureString password, string domain) 120List<Process> children = GetChildProcesses(); 133foreach (Process childProcess in children) 303private bool IsParentOf(Process possibleChildProcess) 315private bool Equals(Process process)
System\Diagnostics\ProcessManager.Linux.cs (4)
41return Process.GetUntruncatedProcessName(procPid, ref stat); 58if (modules is not null && Process.GetExePath(procPid) is string exePath) 93processName = Process.GetUntruncatedProcessName(procPid, ref stat); 114ProcessName = processName ?? Process.GetUntruncatedProcessName(procPid, ref procFsStat) ?? string.Empty,
System\Diagnostics\ProcessStartInfo.cs (1)
19/// used in conjunction with the <see cref='System.Diagnostics.Process'/>
System\Diagnostics\ProcessThread.Linux.cs (5)
44return Process.TicksToTimeSpan(stat.stime); 48private DateTime GetStartTime() => Process.BootTimeToDateTime(Process.TicksToTimeSpan(GetStat().starttime)); 63return Process.TicksToTimeSpan(stat.utime + stat.stime); 79return Process.TicksToTimeSpan(stat.utime);
System.Diagnostics.TextWriterTraceListener (2)
System\Diagnostics\XmlWriterTraceListener.cs (2)
259using Process process = Process.GetCurrentProcess();
System.Net.Ping (3)
System\Net\NetworkInformation\Ping.PingUtility.cs (3)
18private Process GetPingProcess(IPAddress address, byte[] buffer, int timeout, PingOptions? options) 53using (Process p = GetPingProcess(address, buffer, timeout, options)) 78using Process pingProcess = GetPingProcess(address, buffer, timeout, options);
System.Windows.Forms (3)
System\Windows\Forms\Application.cs (3)
1303Process process = Process.GetCurrentProcess(); 1329Process.Start(currentStartInfo);
testhost (7)
src\vstest\src\Microsoft.TestPlatform.Execution.Shared\DebuggerBreakpoint.cs (7)
60ConsoleOutput.Instance.WriteLine($"Attaching Visual Studio with PID {vsPid} to the process '{Process.GetCurrentProcess().ProcessName}({processId})'...", OutputLevel.Information); 63AttachVs(Process.GetCurrentProcess(), vsPid); 69private static bool AttachVs(Process process, int? vsPid) 90var attachVsProcess = Process.Start(vsAttachPath, $"{process.Id} {vsPid}"); 132var currentProcess = Process.GetCurrentProcess();
testhost.arm64 (7)
src\vstest\src\Microsoft.TestPlatform.Execution.Shared\DebuggerBreakpoint.cs (7)
60ConsoleOutput.Instance.WriteLine($"Attaching Visual Studio with PID {vsPid} to the process '{Process.GetCurrentProcess().ProcessName}({processId})'...", OutputLevel.Information); 63AttachVs(Process.GetCurrentProcess(), vsPid); 69private static bool AttachVs(Process process, int? vsPid) 90var attachVsProcess = Process.Start(vsAttachPath, $"{process.Id} {vsPid}"); 132var currentProcess = Process.GetCurrentProcess();
testhost.x86 (7)
src\vstest\src\Microsoft.TestPlatform.Execution.Shared\DebuggerBreakpoint.cs (7)
60ConsoleOutput.Instance.WriteLine($"Attaching Visual Studio with PID {vsPid} to the process '{Process.GetCurrentProcess().ProcessName}({processId})'...", OutputLevel.Information); 63AttachVs(Process.GetCurrentProcess(), vsPid); 69private static bool AttachVs(Process process, int? vsPid) 90var attachVsProcess = Process.Start(vsAttachPath, $"{process.Id} {vsPid}"); 132var currentProcess = Process.GetCurrentProcess();
UIAutomationClient (2)
MS\Internal\Automation\HwndProxyElementProvider.cs (2)
429System.Diagnostics.Process targetProcess = null; 432targetProcess = System.Diagnostics.Process.GetProcessById( pid );
UIAutomationClientSideProviders (4)
MS\Internal\AutomationProxies\Misc.cs (1)
1815string processName = System.Diagnostics.Process.GetProcessById((int)processId).ProcessName;
MS\Internal\AutomationProxies\WinEventTracker.cs (3)
475return Misc.ProxyGetClassName(Process.GetProcessById(processId).MainWindowHandle).Equals("ConsoleWindowClass"); 494Process[] localByName = Process.GetProcessesByName("csrss");
vbc (5)
src\roslyn\src\Compilers\Shared\BuildServerConnection.cs (3)
169using var process = Process.GetProcessById(serverProcessId); 651if (Process.Start(startInfo) is { } process)
src\roslyn\src\Compilers\Shared\CompilerServerLogger.cs (1)
125var processId = Process.GetCurrentProcess().Id;
src\roslyn\src\Compilers\VisualBasic\vbc\Program.cs (1)
33using var logger = new CompilerServerLogger($"vbc {Process.GetCurrentProcess().Id}");
VBCSCompiler (6)
src\roslyn\src\Compilers\Server\VBCSCompiler\ClientConnectionHandler.cs (1)
70new ShutdownBuildResponse(Process.GetCurrentProcess().Id),
src\roslyn\src\Compilers\Server\VBCSCompiler\VBCSCompiler.cs (1)
22using var logger = new CompilerServerLogger($"VBCSCompiler {Process.GetCurrentProcess().Id}", options.LogFilePath);
src\roslyn\src\Compilers\Shared\BuildServerConnection.cs (3)
169using var process = Process.GetProcessById(serverProcessId); 651if (Process.Start(startInfo) is { } process)
src\roslyn\src\Compilers\Shared\CompilerServerLogger.cs (1)
125var processId = Process.GetCurrentProcess().Id;
vstest.console (8)
Processors\AeDebuggerArgumentProcessor.cs (1)
193is Process process)
src\vstest\src\Microsoft.TestPlatform.Execution.Shared\DebuggerBreakpoint.cs (7)
60ConsoleOutput.Instance.WriteLine($"Attaching Visual Studio with PID {vsPid} to the process '{Process.GetCurrentProcess().ProcessName}({processId})'...", OutputLevel.Information); 63AttachVs(Process.GetCurrentProcess(), vsPid); 69private static bool AttachVs(Process process, int? vsPid) 90var attachVsProcess = Process.Start(vsAttachPath, $"{process.Id} {vsPid}"); 132var currentProcess = Process.GetCurrentProcess();
vstest.console.arm64 (8)
src\vstest\src\Microsoft.TestPlatform.Execution.Shared\DebuggerBreakpoint.cs (7)
60ConsoleOutput.Instance.WriteLine($"Attaching Visual Studio with PID {vsPid} to the process '{Process.GetCurrentProcess().ProcessName}({processId})'...", OutputLevel.Information); 63AttachVs(Process.GetCurrentProcess(), vsPid); 69private static bool AttachVs(Process process, int? vsPid) 90var attachVsProcess = Process.Start(vsAttachPath, $"{process.Id} {vsPid}"); 132var currentProcess = Process.GetCurrentProcess();
src\vstest\src\vstest.console\Processors\AeDebuggerArgumentProcessor.cs (1)
193is Process process)