mac请用Process p = new Process()
Process.Start不行
不要问为什么
就是踩坑过来的
using (Process p = new Process())
{
p.StartInfo.FileName = "/bin/sh";
p.StartInfo.Arguments = 参数;
p.StartInfo.CreateNoWindow = true;
p.StartInfo.UseShellExecute = false;
p.StartInfo.RedirectStandardError = true;
p.StartInfo.RedirectStandardOutput = true;
p.Start();
p.WaitForExit();
}
``