Commit 6cabdd80 authored by Greg Williams's avatar Greg Williams
Browse files

Another fix for shutting down simulators

parent 5185e805
Loading
Loading
Loading
Loading
+8 −2
Original line number Diff line number Diff line
# Ensure stray simulators are not still running
ps -ef | grep kinetic-simulator | grep -v 'grep' | tr -s ' ' | cut -d ' ' -f 2 | xargs kill $1
KINETIC_SIM = `ps -ef | grep kinetic-simulator | grep -v 'grep' | tr -s ' ' | cut -d ' ' -f 2`
if [! -z "$KINETIC_SIM" ]; then
  echo Killing kinetic-simulator w/ PID: $KINETIC_SIM
  kill $KINETIC_SIM
  echo Killed all kinetic simulators!
else
  echo No kinetic simulators alive to kill.
fi