[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-devel
Subject:    Re: [Moving/Copying Files] Overwriting identical files
From:       Gary Greene <greeneg () tolharadys ! net>
Date:       2010-10-05 2:46:10
Message-ID: 356BA125-0E5B-4054-8D80-103BAD2BCD3D () tolharadys ! net
[Download RAW message or body]

On 30 Sep 2010, at 6:46 AM, David Jarvie wrote:
On Thu, September 30, 2010 12:30 pm, Matthias Fuchs wrote:
> > Hi,
> > 
> > When moving and copying multiple files it can be quite tedious to make out
> > if there are differences for all these files.
> > 
> > 
> > 
> > ====Use Case:====
> > You copy hundreds of text files, knowing that most are the same, but not
> > all.
> > Now you are greated with multiple "Do you want to overwrite XY size Z with
> > XY
> > size W" dialogs.
> > 
> > ====Proposal====
> > What I propose is to not show this dialogs if both files are identical, in
> > the
> > case of copying nothing should happen then, while in the case of moving
> > the source file should be deleted.
> > 
> > To check if a file is identical this should happen in a two step process:
> > 1. Both file sizes equal and smaller a fixed size
> > 2. Calculating the checksums for both files, the check for the fixed size
> > above avoids long lasting calculations
> > 
> > If 1. turns out to be false a dialog should be shown.
> 
> One other thing to consider is what to do if the files are identical but
> have different timestamps. In this case as well, the user needs to be able
> to specify what action to take (i.e. whether to update the timestamp on
> the destination file).
> 
> -- 
> David Jarvie.
> KDE developer.
> KAlarm author - http://www.astrojar.org.uk/kalarm
> 
> 
> > > Visit http://mail.kde.org/mailman/listinfo/kde-devel#unsub to unsubscribe <<
> 

One big issue I see with this is that the user might run into a one in a million \
chance of checksum collisions (they do occur, and are mathematically provable). This \
would open the door to the possible chance of data loss, which I'm VERY not in favour \
of. While a byte-for-byte check might be a good idea, it really will slow certain \
operations down a lot, which means that if that is added, this needs to be off by \
default since it will kill any notebook or mobile user.  
> > Visit http://mail.kde.org/mailman/listinfo/kde-devel#unsub to unsubscribe <<


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic