Skip to content

Instantly share code, notes, and snippets.

@sullust
Created February 19, 2013 17:15
Show Gist options
  • Save sullust/4987880 to your computer and use it in GitHub Desktop.
Save sullust/4987880 to your computer and use it in GitHub Desktop.
kill tree
#!/bin/bash
PID=$1
for i in `pstree -p $PID | grep -oE '[0-9]+' | sort -u`; do
kill $i;
done;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment