Here is the scenario :
An ant script is launched on computer1, logged on computer2 using sshexec ant task to call a shell script that calls itself another ant script.
The main script looks like
<target ...>
<sshexec host="*" username="*" password="*" command="someShellScript.sh" />
</target>
The remote script is basic :
#!/bin/sh
setting some env vars
ant buildfile.xml
All scripts are correctly executed, but when the remote build fails, the main Ant script return BUILD SUCCESSFUL instead of FAILED.
I guess it uses the result of the sh script.
Is there a way to get the second Ant script result ? But maybe, there is a better way to achieve this ?
Thanks