Hi Alexander,
if I understand correct, the last returncode, in this case "echo -n" which 
always should be 0 is given back. Is this correct?
Would it be a good idea to have a different return code, if no files are found 
(should be server reply 550 in case of FTP) than for other errors like 
"connection can't be established" or a "permission denied"? This would make a 
specific control possible, that allows the situation where no files are found 
at remote side.

Thanks for your thoughts regarding this topic!

Best regards,
Tilo

> -----Original Message-----
> From: Alexander V. Lukyanov [mailto:[email protected]]
> Sent: Thursday, November 25, 2010 4:00 PM
> To: Mütze, Tilo, NMI-OPP
> Cc: [email protected]
> Subject: Re: mget "No files found"
> 
> On Thu, Nov 25, 2010 at 12:10:15PM +0000, [email protected] wrote:
> > we are using lftp in a batch processing with "cmd:fail-exit yes;" set. Now 
> > there is
> a requirement, that if no files are found during a "mget -E *"-command ("no 
> files
> found"), the whole processing continues, instead of having lftp fail with 
> exit code
> 1.
> 
> Try:
>       mget * || echo -n
> 
> --
>    Alexander.

Reply via email to