$ dpkg-divert --list /etc/krb5.conf
diversion of /etc/krb5.conf to /etc/krb5.conf.debathena-orig by
debathena-kerberos-config
$ dpkg -S /etc/krb5.conf
diversion by debathena-kerberos-config from: /etc/krb5.conf
diversion by debathena-kerberos-config to: /etc/krb5.conf.debathena-orig
Parsing the output of dpkg -S has the same problem as parsing the output
of dpkg-divert --list $file. That output could change over time (either
because of internationalization or because a better format for the dpkg -S
output is developed). I'm not enthusiastic about maintaining a magic
regular expression that extracts the package name from either output
format that will continue working forever.
I consider this option to be an analog of "dpkg-divert --truename" -- a
mechanism for software not part of dpkg to query the diversions database
in a way that won't require any ugly transitions in the future.
-Tim Abbott
On Sat, 7 Jun 2008, Raphael Hertzog wrote:
Hello,
On Sat, 07 Jun 2008, Timothy G Abbott wrote:
dpkg-divert should provide an option to find out what package diverts a
given file (currently the only way to extract this information is to
parse the dpkg-divert output, which is not ideal).
I've attached a patch against current git to add this functionality.
dpkg -S file also gives the desired information. Was that not suitable?
Cheers,
--
Raphaël Hertzog
Le best-seller français mis à jour pour Debian Etch :
http://www.ouaza.com/livre/admin-debian/