I’m running a script that performs a command that lasts too long, so I want to interrupt it. Any help? I’ve tried to search a lot, and I’ve been pointed to the kill command. Although, I can’t get it to work. By the way, I’m using a Mac OS X. Thanks!
Share
Assuming you have the process’ PID, send it a SIGINT signal:
If you don’t have the PID you can try
pkillorkillall, but they’re somewhat less safe; a PID is the only way to uniquely identify a process. Right after you spawn the other process the PID should be in $!, so you can save it then