How does it work: What package can open a file?

Tom Hughes tom at compton.nu
Wed Mar 13 14:51:08 UTC 2013


On 13/03/13 14:40, Richard Shaw wrote:

> When you try to open a file for which you have no package installed
> that handles that file type, there is a GUI that pops up and asks if
> you want it to search for a package that can handle the file.
>
> How exactly does this mechanism work? I'm assuming there is some
> meta-data in the RPM package that provides this information?

I think it happens because the package has a provide of the form:

   mimehandler(application/csv)

Try "rpm -q --provides libreoffice-calc" for example.

In turn rpmbuild creates those automatically from the mime types listed 
in any desktop files it finds in the package.

Tom

-- 
Tom Hughes (tom at compton.nu)
http://compton.nu/


More information about the devel mailing list