Calling script - Called script concept.

Hi Guys,

I am new to unix and would like to know the basics about calling a shell script from another shell script.

I would like to know if the calling script can finish in any way before the called script actually gets executed completely. I want this to happen :cool:

For Example : If I am calling b.sh from a.sh, I do not want a.sh to be waiting for b.sh to get executed completely. Is there any way for doing it ?

Khedu.

Easy. Just add an ampersand at the end of the command you want to have execute in parallel with the following commands in the main script.

echo Start
./calledscript &
echo End

#calledscript
echo Middle