How to wait and kill a timeout process in Powershell

前端 未结 2 698
旧时难觅i
旧时难觅i 2021-01-05 05:30

Using Powershell 2.0 in a Windows 7 desktop

I want to create a process to run an ant command, and then wait for that process to finish in several minutes. If time ou

2条回答
  •  再見小時候
    2021-01-05 06:12

    If you want to kill the entire process tree, you need to also find and stop the child processes.

    Here's a good article that explains it and shows you how to do that:

    http://powershell.com/cs/blogs/tobias/archive/2012/05/09/managing-child-processes.aspx

提交回复
热议问题