It is best that you read the Advanced bash scripting guide available at http://tldp.org/LDP/abs/html/
If all you want to do now is create your own command which simply calls another existing linux command, check out "alias"
There is nothing like "my command". In other words any executable is as good as a command to Linux.
Anything whose x flag is set can be executed as a command on command line by giving full path. It's ur responsibility to ensure the file actually an executable (e.g. shell, perl, py,... script or c/c++ executable...). $ /home/dir/myScript.pl If you do not specify full path to teh command linux looks up all dirs in PATH variable. So if you add "/home/dir" to PATH, you don't have to specify full path on cmd line
$ echo $PATH
See shell variables section in man page of your shell.