Calling shell script within shell script

Hi All,

I have a simple script that has 8 more scripts being called within it.
Like below

Main Script.sh has within it like below
-----------------------

Script1.sh
Script2.sh
Script3.sh
Script4.sh
Script5.sh
Script6.sh
Script7.sh
Script8.sh

-----------------------------

Now I want 2 to run after 1 finishes and 3 after 2 and likewise until 8 as each script create a huge file which can take time to complete and it cannot be a fixed value(so cannot use sleep).

Please let me know will unix automatically wait for script 1 to finish for script 2 to start and so on

or

should I use (& and wait) combination to handle this.

Thanks

Your script as written above will not start Script2.sh until Script1.sh exits. As long as Script1.sh doesn't start anything asynchronously that hasn't completed before it exits; you will be fine.

Can you explain what you mean by asynchronously??

Asynchronously means that it contains a command that ends with & and exits without waiting for that command to complete; or calls a program that starts some processing in the background and exits before that background processing completes.