Shell script is  a text file that contain a series commands for a Unix-based operating system . Firstly we need an editor like Vim, to install vim

As you know vim is a programmer editor . To open a vim text file write to console

For writing to editor: type “a”,  now  you can write to editor and to exit from the editor press ESC then write “:wq”  this means write and quit. You can more info here.

Let’s start to write first Shell Script

Open your editor.




After writing script, I will set to script execute permission.

now I will execute.





to be continued..