Max Desyatov wrote:
Bernhard Lehnert <b.lehn...@gmx.de> writes:
Windows has a command "start" which you can use e.g. via System.Process.proc.
Thank you, Magnus - this is exactly what I was looking for. (By the way,
someone should implement something like this for GNOME and KDE,
too ;-) )

You can do that using MIME, look at /etc/mailcap, it already contains
all what you need to run appropriate process for exact MIME-type.  As
long as it's supported in your distribution.

Is there a command line interface for that?
Or maybe a lib that's easy to wrap?

If you want to query the Gnome MIME database (which is separate from /etc/mailcap) you can use 'xdg-mime'.

/M

--
Magnus Therning                        (OpenPGP: 0xAB4DFBA4)
magnus@therning.org          Jabber: magnus@therning.org
http://therning.org/magnus         identi.ca|twitter: magthe

Attachment: signature.asc
Description: OpenPGP digital signature

_______________________________________________
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe

Reply via email to