shell/fzf: add bin/fzf-kill

This commit is contained in:
Henrik Lissner 2017-04-25 17:19:06 -04:00
parent 5a65cc9960
commit bf926c8e84

9
shell/fzf/bin/fzf-kill Executable file
View file

@ -0,0 +1,9 @@
#!/usr/bin/env bash
# Interactively select a process to kill.
pid=$(ps -ef | sed 1d | gui-fzf -m | awk '{print $2}')
if [[ $pid ]]; then
xargs kill -${1:-9} <<< "$pid"
fi