kill for platform

Kill a process using the process id.

Signature

> kill {flags} (pid) ...rest

Flags

  • --force, -f: forcefully kill the process
  • --quiet, -q: won't print anything to the console
  • --signal, -s {int}: signal decimal number to be sent instead of the default 15 (unsupported on Windows)

Parameters

  • pid: Process id of process that is to be killed.
  • ...rest: Rest of processes to kill.

Input/output types:

inputoutput
nothingany

Examples

Kill the pid using the most memory

> ps | sort-by mem | last | kill $in.pid

Force kill a given pid

> kill --force 12345

Send INT signal

> kill -s 2 12345