Upsilon-VsCode/Client/node_modules/vscode-languageclient/lib/utils/terminateProcess.sh

16 lines
528 B
Bash
Raw Normal View History

2019-02-17 17:07:28 +00:00
#!/bin/bash
# --------------------------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for license information.
# --------------------------------------------------------------------------------------------
terminateTree() {
for cpid in $(pgrep -P $1); do
terminateTree $cpid
done
kill -9 $1 > /dev/null 2>&1
}
for pid in $*; do
terminateTree $pid
done