Me helped, as explained here:

killall unity-panel-service

Few commands which I am using this moment:

top - to display running processes
pgrep chrome | xargs kill - to kill all chrome processes
whereis - locate the binary, source, and manual page files for a command
ifconfig - I am using this command to get my IP address

Just few things which I learned.


myList="a b c d";
for my in $myListAry; do
  echo $my;

No spaces at sign of equality when assigning a value to variable. 

Instead of quotes you can use parentheses also, but in that case I was receiving some stupid error from Grunt:

Syntax error: "(" unexpected (expecting "}")

Also, in my case this example also works (without array):

myList="a b c d";
for my in $myList; do
  echo $my;

I had to do it without converting to array, because in the Grunt I was receiving error:

"Bad substitution"

Those two examples you can download from here. To test it, save it in a folder, lets say in Downloads, go to that folder:

cd Downloads

Load file:

. ./

execute either:




To replace string in a (same) file:

sed -i.bak 's/"'$my'"/"someString"/g' /home/stanko/someFile.txt

Notice that I was using double quotes, because lets assume that in your file you want "someString" replace with my variable but to have quotes. Under single quotes dollar sign ($) is not recognized, that is why I had to "close" quotes.

Switch -i means that I want to replace string in a same file.

Also, when I was loading bash script from terminal window, it seems that variables are populated like global, just once and never again, that is why I had to close terminal window, open it again, and again to load my script, otherwise my changes inside of variables would not be visible....

To comment block, use something like this:

echo before comment
: <<'END'
bla bla
echo after comment

Copy/pasted from here.

Copy paste from here:

The vertical bar character is used to represent a pipe in commands in Linux and other Unix-like operating systems. A pipe is a form of redirection that is used to send the output of one program to another program for further processing.

Example which I use to kill all chrome instances:

pgrep chrome | xargs kill