卸载时退出所有node.js进程
This commit is contained in:
parent
2d1337f044
commit
524d7fe186
@ -112,8 +112,8 @@ namespace setup
|
||||
|
||||
ll = pro.StandardOutput.ReadToEnd() + pro.StandardError.ReadToEnd(); //读取输出
|
||||
|
||||
pro.WaitForExit(); //等待程序执行完退出进程
|
||||
pro.Close();//结束
|
||||
pro.WaitForExit(); //等待程序执行完退出进程
|
||||
pro.Close();//结束
|
||||
return ll;
|
||||
}
|
||||
catch (Exception ex)
|
||||
@ -334,8 +334,8 @@ SOFTWARE.");
|
||||
else
|
||||
{
|
||||
Console.WriteLine("What do you want to do?");
|
||||
Console.WriteLine("1) Install (I accept the MIT License.)");
|
||||
Console.WriteLine("2) Uninstall");
|
||||
Console.WriteLine("1) Install (I accept the MIT License)");
|
||||
Console.WriteLine("2) Uninstall(Will exit the Node.js process)");
|
||||
Console.WriteLine("3) Exit");
|
||||
Console.Write("#?");
|
||||
cmd = Console.ReadLine();
|
||||
@ -398,6 +398,7 @@ SOFTWARE.");
|
||||
{
|
||||
Console.WriteLine(ExecuteOutCmd("C:\\WINDOWS\\dc-agent\\bin\\dc-agent.exe", "stop"));
|
||||
Console.WriteLine(ExecuteOutCmd("C:\\WINDOWS\\dc-agent\\bin\\dc-agent.exe", "remove"));
|
||||
runCmd("taskkill /fi \"imagename eq node.exe\" /f");
|
||||
|
||||
Thread.Sleep(1500);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user