duplicity-talk
[Top][All Lists]
Advanced

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

Re: [Duplicity-talk] File / Directory names with spaces


From: Richard Scott
Subject: Re: [Duplicity-talk] File / Directory names with spaces
Date: Tue, 06 Jul 2010 10:59:46 +0100
User-agent: RoundCube Webmail/0.3.1

Hi Peter,

lol... I said it was creative, not well written ;-)

At the time there was some reason I used the 2nd find statement but I
can't remember what it was now :-(
Your refined code seems to work ok, so I'll give that a go and see what
happens!

Cheers,

Rich

> Yikes!
> 
> Am I reading this shell snippet correctly?:
> 
> It searches the entire file system for files called .duplicity-ignore, 
> and for each file it finds, it searches the entire file system *again*? 
> So if you have 45 .duplicity-ignore files, you end up searching the 
> entire file system 46 times? Lets at least hope you don't have any slow 
> network attached storage.
> 
> Wouldn't it really help to avoid that nested "find /"? I haven't tried 
> it, but would this work instead?:
> 
> --- code start ---
> # Delete any pre-existing file for good measure so it doesn't
> # just grow and grow and grow
> rm -f /var/tmp/exclude.list
> 
> find / -type f -name .duplicity-ignore -print0 | while read -d $'\0'
file
> do
>    echo $(dirname "$file") >> /var/tmp/exclude.list
> done
> --- code end ---
> 
> Peter



reply via email to

[Prev in Thread] Current Thread [Next in Thread]