Fixing the mime horror ini Debian

Vincent Bernat bernat at debian.org
Fri Jul 13 18:26:06 UTC 2012


 ❦ 13 juillet 2012 12:18 CEST, Per Olofsson <pelle at dsv.su.se> :

> 1. Rewrite xdg-utils so that it is robust and always works. Instead of
> relying on desktop environments, it should do the needed work by
> itself. Currently it's something of a hack, especially when running in
> "generic" mode. It should probably be written in another language than
> shell (e.g. Perl, Python, C). A nicer user interface for the command
> line wouldn't hurt either.
>
> 2. Make all other packages either use xdg-utils or follow the
> freedesktop.org MIME specs.

Yes, I also think this is a good plan.

Relying on existing desktop tools is too difficult. They get deprecated
(for example, gnome-open has been replaced by gvfs-open) or they cannot
be adapted easily because maintainers usually don't care about those
corner use cases. For example, gvfs-open does not wait for the viewer to
terminate, this makes difficult for mailers to pass a temporary
file. See:
 - http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=677430
 - https://bugzilla.gnome.org/show_bug.cgi?id=652262
 - https://bugzilla.gnome.org/show_bug.cgi?id=678504

Once you get a working xdg-open, you can get a compatibility layer for
the mailcap stuff:
  */*; xdg-open '%s'; test=test -n "$DISPLAY"

Or something more sensible like:
  image/gif; xdg-open -t image/gif '%s'; test=test -n "$DISPLAY"
  image/png; xdg-open -t image/png '%s'; test=test -n "$DISPLAY"
  [...]

The remaining problem is defining the priority of such entries compared
to entries inserted by packages still supporting mailcap.
-- 
#if 0
	2.2.16 /usr/src/linux/fs/buffer.c
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 835 bytes
Desc: not available
URL: <http://lists.alioth.debian.org/pipermail/pkg-gnome-maintainers/attachments/20120713/2dade688/attachment-0001.pgp>


More information about the pkg-gnome-maintainers mailing list