1 Answer
1

Shell functions are a way to group commands for later execution using a single name for the group. They are executed just like a "regular" command. When the name of a shell function is used as a simple command name, the list of commands associated with that function name is executed. Shell functions are executed in the current shell context; no new process is created to interpret them.

Thanks! I just forgot about functions. It seems so weird to write only a single function header without blocks in the command line instead of in the script. I was totally confused at first.
–
moleculeaNov 24 '13 at 6:32