I am calling a script from main script.
The called script (second script) have to return some value, i can use exit to pass but in exit i have to pass some other value.
i used "export Var", but this command resides in a function of second script.
could you please tell me how to pass a variable(that resides in function) of called script that has to be passed to calling script,
if do like this it will proceed further statements of the second script or skip execution.
remember i am exporting a variable from a function in second script.
exit will cause the calling shell or shell script to exit
with the exit status specified by n. If n is omitted the
exit status is that of the last command executed (an EOF
will also cause the shell to exit.)
return causes a function to exit with the return value
specified by n. If n is omitted, the return status is that
of the last command executed.