diff --git a/README.md b/README.md index 68c98cf..800dd22 100644 --- a/README.md +++ b/README.md @@ -5,3 +5,4 @@ repository to house scripts that were not useful enough to earn a place in there ## Overview - `recursive.sh`: a script that calls itself. - `self_destruct.sh`: a script that deletes itself. + - `suicidal.sh`: a script that kills the process that's executing it, i.e. itself. diff --git a/suicidal.sh b/suicidal.sh new file mode 100755 index 0000000..2b98f5c --- /dev/null +++ b/suicidal.sh @@ -0,0 +1,4 @@ +#!/bin/sh +# A script that kills the process that's executing it, i.e. itself + +pkill "$(basename "$0")"