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

Re: [PATCH] hrmib cache for dpkg



Goswin von Brederlow wrote:

But if you do have the same name-version installed more than once then
it would only show up once and removing one might delete the file,
right.

I was thinking more along the line of 2 packages with the same version
but different epoch and upgrading from one to the other. If removing a
package removes the cache file then the old package would remove the
new packages file.

Right, that part of the implementation can most certainly be improved.
No need to store the epoch into the filenames because of it, though ?

Grepping through the log output is probably worse than grepping status, which is already twice as slow for bash-completion than checking a file.

Not sure what my zsh does but the first time I <tab> apt-get it takes
a second or two and then it has it cached.

Apparently* it forks a call to `dpkg --get-selections` and parses that,
before storing the results into an internal cache (that gets stale, etc).

* http://zsh.cvs.sourceforge.net/viewvc/zsh/zsh/Completion/Debian/ Type/_deb_packages?view=markup

--anders


Reply to: