wait for unity processes to die

This commit is contained in:
Cat Flynn 2021-01-30 15:19:19 +00:00
parent a160eddf59
commit 7f7bc2123c
1 changed files with 5 additions and 4 deletions

View File

@ -7,11 +7,12 @@ editorlogpath="$HOME/Library/Logs/Unity/Editor.log"
editorpath="/Applications/Unity/Hub/Editor/$unityversion/Unity.app" editorpath="/Applications/Unity/Hub/Editor/$unityversion/Unity.app"
# find and kill existing unity instances # find and kill existing unity instances
if pgrep -x Unity echo "terminating existing unity processes..."
then while pgrep -x Unity > /dev/null
echo "terminating existing unity processes..." do
kill $(pgrep Unity) kill $(pgrep Unity)
fi sleep 1
done
# remove previous Editor.log # remove previous Editor.log
echo "removing previous editor log..." echo "removing previous editor log..."