The 'bail' Command - jmadison222/jamaratus GitHub Wiki
Generate kill statements for all processes but the current terminal.
> bail help
Generate kill statements for all processes but the current terminal.
This command is intended for situations where you launch lots of parallel
processes, and something goes wrong. But the nature of the failure does
not end the processes. You then need to kill lots of processes yourself.
This script will NOT actually kill processes. It follows the rule of not
automating destructive actions. It does everything up to that final
step, but leaves it to you to actually execute the kill commands by
pasting them in some terminal session.
It is a bit of a blunt instrument. The only thing it tries not to kill
is your terminal and things that are likely part of your interactive
session, such as security daemons. Everything else gets on the list.
Examples:
> bail
----------------------------------------------------------------------
-- List the commands to kill all but the current terminal.
--
198|199 are security processes and not listed.
202|5468|5469|5470|5471|5472 are your current terminal and not listed.
kill -9 32
kill -9 34
kill -9 203
kill -9 5473
kill -9 5474
kill -9 5475
kill -9 5476
kill -9 5477
kill -9 5478
Usage: bail <action:list> # Where action is:
help Help by showing these instructions.
list List the commands to kill all but the current terminal. [default]