smart and desktop environment specific MIME defaults

Stanislav Brabec sbrabec at suse.cz
Thu Feb 10 05:33:41 PST 2011


Hallo.

I have been working on an implementation of smart utilities for
maintenance of MIME defaults in glib (gtk+, GNOME) and
desktop-file-utils that may make defaults desktop specific.

The implementation is capable:
- Parse all desktop files and inspect Categories and MimeType keywords.
- Automatically maintain defaults list for all MIME types using a simple
  configuration file and simple heuristic.
- Use different defaults for the same MIME type and the same application
  started from the different environment (i. e. nautilus in GNOME will
  use file-roller for ZIP archives, but when started from KDE, it will
  use ark).

It helps to maintain complete and correct defaults.list and improves
behavior of systems with more than one desktop environment installed.

The implementation is available here:
Sources:
https://bugs.freedesktop.org/show_bug.cgi?id=30214
https://bugzilla.gnome.org/show_bug.cgi?id=630171
Binaries (openSUSE, Fedora):
https://build.opensuse.org/project/show?package=&project=home%3Asbrabec%3Amime-defaults
(for glib, just libgio replacement is sufficient)

Note that you have to set environment variable DESKTOP_SESSION in the
particular session init script. (See the discussion in the bug.)

Comments are welcome.
-- 
Best Regards / S pozdravem,

Stanislav Brabec
software developer
---------------------------------------------------------------------
SUSE LINUX, s. r. o.                          e-mail: sbrabec at suse.cz
Lihovarská 1060/12                            tel: +49 911 7405384547
190 00 Praha 9                                  fax: +420 284 028 951
Czech Republic                                    http://www.suse.cz/



More information about the xdg mailing list