Since this thread has been forced out of the zero reply list... I'll start to tell something (hopefully) useful.
@izghitu: if you need to improve or refresh your general knowledge about bash scripting, better to start from the official documentation, for example:
Bash Reference Manual
Bash Guide for Beginners
Advanced Bash Scripting Guide
just to mention some of them. Command lines arguments are often referred as positional parameters
. Inside a bash script you can retrieve their value using $1, $2, $3 and so on. Or you can parse them one at a time using the shift
built-in in a loop. However, what you really need is a way to manage command line's options. In this case the getopts
built-in or the getopt
external command are your friends. You might start to look for all these terms in the cited documentation. Hope this helps.