On Thu, Feb 14, Stanislav Visnovsky wrote:
========= Added 'packagesdir' option to zypp.conf to re-define a prefix to keep the downloaded packages. Default is '/var/cache/zypp/packages'
{ // does the current file exists in the current cache? Pathname cached_file = *it_cache + (*it_res)->location.filename(); + + MIL << "Trying cached file: " << cached_file << endl; + if ( PathInfo( cached_file ).isExist() ) { + MIL << "File exist, testing checksum " << (*it_res)->location.checksum() << endl; + // check the checksum
It might be worth maintaining an index by checksum for the cached files. If you look for a package in repo A, the same package (same checksum) might be already available in repo B. We should not download it to the new location as well. Another usefull feature would be to allow to 'inject' packages created by a delta into the chache. The package provider had to look for the package by checksum before trying to use delta. So there would be no need to apply the delta twice. If provided via a delta, the recreated package could be injected into the cache. -- cu, Michael Andres +------------------------------------------------------------------+ Key fingerprint = 2DFA 5D73 18B1 E7EF A862 27AC 3FB8 9E3A 27C6 B0E4 +------------------------------------------------------------------+ Michael Andres YaST Development ma@novell.com SUSE LINUX Products GmbH, GF: Markus Rex, HRB 16746 (AG Nuernberg) Maxfeldstrasse 5, D-90409 Nuernberg, Germany, ++49 (0)911 - 740 53-0 +------------------------------------------------------------------+ -- To unsubscribe, e-mail: zypp-devel+unsubscribe@opensuse.org For additional commands, e-mail: zypp-devel+help@opensuse.org