Discuss (FTP) and (SFTP, FTPS and SCP), our Java file transfer clients.
no avatar
User

cmgharris

Posts

3

Joined

Thu Oct 02, 2008 9:26 pm

Location

Carlisle, UK

Return codes from ScriptEngine

by cmgharris » Thu Oct 02, 2008 9:32 pm

I am trying to use the edtFTPj/PRO ScriptEngine to write unix shell scripts.
However its usefulness is severely compromised because, as far as I can see, it does not set a return code on exit.
I would like the option to have it set a non-zero return code (as seen in $?) to reflect the failure of the last command executed.
Is this possible? or is there any other easy way of knowing if a command has failed (i.e. easier than capturing the text output, and parsing for failure messages)?

Thanks
no avatar
User

support2

Posts

3987

Joined

Tue May 18, 2004 8:30 am

Re: Return codes from ScriptEngine

by support2 » Thu Oct 02, 2008 11:07 pm

Yes, this definitely needs doing. If you are interested please send us an email (to support) & we can send you a new build to try out - should be able to do by Monday, possibly even Friday.
no avatar
User

cmgharris

Posts

3

Joined

Thu Oct 02, 2008 9:26 pm

Location

Carlisle, UK

by cmgharris » Thu Oct 02, 2008 11:28 pm

I've sent an email to support, requesting, in short "to have the script terminate on the first command that fails, and set a non-zero return code".

Please let me know if you don't get it.

Thanks for this encouraging response,
no avatar
User

cmgharris

Posts

3

Joined

Thu Oct 02, 2008 9:26 pm

Location

Carlisle, UK

by cmgharris » Sat Oct 04, 2008 2:01 am


Who is online

Users browsing this forum: No registered users and 11 guests

Powered by phpBB ® | phpBB3 Style by KomiDesign