mirror of
https://github.com/azaion/annotations.git
synced 2026-04-22 06:36:31 +00:00
21 lines
513 B
C#
21 lines
513 B
C#
using System.Diagnostics;
|
|
|
|
namespace Azaion.Common.Services;
|
|
|
|
public class ProcessLauncher : IProcessLauncher
|
|
{
|
|
public void Launch(string fileName, string arguments, string? workingDirectory = null)
|
|
{
|
|
using var process = new Process();
|
|
process.StartInfo = new ProcessStartInfo
|
|
{
|
|
FileName = fileName,
|
|
Arguments = arguments,
|
|
WorkingDirectory = workingDirectory ?? "",
|
|
CreateNoWindow = true
|
|
};
|
|
process.Start();
|
|
}
|
|
}
|
|
|