Open netcrns opened 5 years ago
I guess the current kill command should be renamed to killpid
or something and then kill
would kill by process name.
Wouldn't it be possible to have both functions in one command? Or is that too complicated to achieve? My guess is that you could check whether it's a PID or a process name with conditionals. Then again, I've only just started with low-level languages, so I might as well be wrong.
I was thinking that process names could just be numbers too.
Using
:kill <ID>
is a very specific action, and very helpful for sure. But I believe the ability to kill every process with a specific name would be handy for many as well. If a program runs multiple processes, it can be a bother to kill it entirely with NTop. You'd have to:search
for the name and mark every process that comes up, and only then you'd be able to kill it withshift-k
. Maybe you could even include regexp searching.Let's take Firefox as an example. You'd have to
:search firefox
and spamn
&space
, then finish it off withshift-k
to actually close that program. It'd be much more efficient to just use:kill firefox
.