[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: mirror exclude (was: lftp - mirror: very slow)



No need to CC me, I'm on the lftp-list now :)

Great Alexander, thanks.
Now it's working as advertised. Some examples in strategic places
on the man page would benefit the rest of the world, if I'm alowed to
have that wish.

The one downside of using the

  -x "exclude-stuff$"

syntax, I noticed, is that it's not intuitive. As I said,
examples would help a lot.

Another thing I noticed is that unwanted directories/files which were
already there (in the mirrored directory tree) did not go away.
Reading the documentation again, I understand such an option is not
supported, yet :) Could you please put it on the wishlist? I presume
there's no workaround for something like that, or is there?

Anyway, I'm greatful. You made my day :)

Cheers,
Cristian

On Tue, 13 Mar 2001, Alexander V. Lukyanov wrote:

> On Mon, Mar 12, 2001 at 07:57:44PM +0100, Cristian Ionescu-Idbohrn wrote:
> > open hftp://ftp.sunet.se
> > mirror -v -c -e -x \
> > "(mail-archives|old|snapshots)$" \
> > pub/lang/cygwin /home/cii/cygwin/mirror/cygwin
> >
> > but no joy :( I'd like to see what's going on. What debug value should
> > I use?
>
> It turned out to be a bug. Try this patch:
>
> Index: HttpDir.cc
> ===================================================================
> RCS file: /home/lav/cvsroot/lftp/src/HttpDir.cc,v
> retrieving revision 1.60
> retrieving revision 1.61
> diff -u -r1.60 -r1.61
> --- HttpDir.cc	2001/02/13 10:07:30	1.60
> +++ HttpDir.cc	2001/03/13 08:46:30	1.61
> @@ -18,7 +18,7 @@
>   * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
>   */
>
> -/* $Id: HttpDir.cc,v 1.60 2001/02/13 10:07:30 lav Exp $ */
> +/* $Id: HttpDir.cc,v 1.61 2001/03/13 08:46:30 lav Exp $ */
>
>  #include <config.h>
>  #include "ascii_ctype.h"
> @@ -1220,6 +1220,10 @@
>        Delete(ubuf);
>        ubuf=0;
>        m=MOVED;
> +
> +      result->ExcludeDots();
> +      if(rxc_exclude || rxc_include)
> +	 result->Exclude(path,rxc_exclude,rxc_include);
>
>        get_info_cnt=result->get_fnum();
>        if(get_info_cnt==0)
>
> --
>    Alexander.
>

-- 
Murphy was an optimist.



Reply to: