mime apps specification

Jerome Leclanche adys.wh at gmail.com
Sun Apr 13 10:54:15 PDT 2014

On Sun, Apr 13, 2014 at 6:34 PM, Vladimir Kudrya <vladimir-csp at yandex.ru> wrote:
> Hello everyone!
> I am translator and tester of SpaceFM file manager.
> There were some heated discussion of the new mime spec
> https://github.com/IgnorantGuru/spacefm/issues/450
> As it is still in flux I'd like to share some thoughts. The ordering and
> precedence in the spec is somewhat shady. For example current spec does not
> allow removed association to be re-added further downstream. David Faure
> replied that clarifications will follow.

I think it was clarified in the spec but you are supposed to read the
desktop files from most local to most global while maintaining
"Removed Associations" as a blacklist.

Example, simplifying to only "global" and "local" namespaces:

[Removed Associations]

[Added Associations]

Reading local first, you will find the foo.desktop file *before* you
arrive to the item in the global blacklist.

> In the meantime, I would like to make some fresh-eyed input.
> Do the following statements cover the intended meaning of the algorithm?
> Let's say these are both questions and suggestions:
> The ordered list of associations of given mimetype is forming from upstream
> to downstream, every downstream part takes precedence and overrides its
> upstream part.
> Items in [Default Applications] influence ordering only.
> Items in [Added Associations] influence presence only (just as content of
> .desktop files).
> Items in [Removed Associations] are removed from list in current iteration.

It's a lot simpler if you just look at it the other way.

J. Leclanche

> The order of sources of item is this (from upstream to downstream):
> $XDG_DATA_DIRS .desktop files >
> $XDG_DATA_DIRS mimeapps.list >
> $XDG_DATA_DIRS $desktop-mimeapps.list >
> $XDG_CONFIG_DIRS mimeapps.list >
> $XDG_CONFIG_DIRS $desktop-mimeapps.list >
> $XDG_DATA_HOME .desktop files >
> $XDG_DATA_HOME mimeapps.list >
> $XDG_DATA_HOME $desktop-mimeapps.list >
> $XDG_CONFIG_HOME mimeapps.list >
> $XDG_CONFIG_HOME $desktop-mimeapps.list >
> Another opinion is voiced by IgnorantGuru, the developer of SpaceFM. He
> points out that separate [Default Applications] is redundant and is a big
> step away from KISS principle. List ordering in [Added Associations] should
> be enough to change/determine default application.
> Thank you for your time!
> _______________________________________________
> xdg mailing list
> xdg at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/xdg

More information about the xdg mailing list