Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

4
  • 1
    [ is a built in of bash. But behaves as if it is a separate command. On some shells it is. You can find [ in /usr/bin/[, and it has a man page. Commented Jul 13, 2016 at 9:09
  • Thanks for the reply. Do we need to provide the pid in the above script ? I just have the process name which I want to stop. I am very new to scripting and trying to learn hence please bear with me for the stupid questions. Commented Jul 13, 2016 at 9:10
  • @user179309 in the above script, it looks by name, just like you did with whoami, and the APP_ID will be a single or multi-line string including all the process ids (depending on how many processes are found). Commented Jul 13, 2016 at 9:15
  • @richard thanks, I guess you're right that I implied it's the same when it's not, so I fixed that. Commented Jul 13, 2016 at 9:19