Suppose I wanted to kill firefox , I just write pidof fi(press tab)refox (appears on its own) , then I write ' kill 'id given by pidof' ' on terminal.
I know that I can write 'kill `pidof firefox` ' but the autocomplete does not work . So I wanted a command like mykill firefox (on which tab completion also work) which on the background runs 'kill `pidof firefox` '
mykill process name (with tab completion) -> kill `pidof process name`
pkill
andkillall
. They can act in a similar way. To spot the differences between them you may give a look to this answer or to the other of the post. – Hastur Jun 11 '14 at 20:22