Hi Alex and others,

I would like to use lftp to automate reverse mirroring of web-albums
generated by http://booh.org/

So far I've come up with the following script to use with -f:

set net:max-retries 1
open <user-entry>
lcd /local/path/to/generated/album
mirror -R <album-basename>

("set net:max-retries 1" tries to workaround "useless" reconnects when
user entered an error in site name or credentials - but it would be
good to avoid retries on these problems yet benefit from data
transmission errors retries, though I haven't investigated that yet)

My problem is to handle the case when the opened URL has a mistake in
the path part. So far (with fish) I've seen something like:

cd: Access failed: /bin/sh: line 8: cd: /public_html: No such file or directory

and the script carries on, and would mirror at an improper remote
location I guess.

Is there any way to detect this kind of errors? I know lftp tries to
carry on as much as possible when facing non fatal errors, but in that
case it is just not what I'd like :/

Thanks for any help!

-- 
Guillaume Cottenceau - http://zarb.org/~gc/

Reply via email to