On 5 March 2013 12:41, Jerome Leclanche <[email protected]> wrote: > - PNG is a massively popular file format, who the hell thought this was a > good idea?
Seconded ;-) Bastien: > Your implementation returns results differently from the one we use in > shared-mime-info itself. Looking at the implementation in PyXDG, it's quite a long way from the recommended checking order in the spec. I'll have to sort that out properly when I've got time, but for now it should be improved by making the first suffix from the globs file win, not the last one (they're sorted by decreasing weight). Jerome: > I think resulting behaviour should be the same as what you would do when getting two conflicting, same-priority magics. The spec doesn't seem to advocate a behaviour in this case[1]. In general, if there are conflicts, they should be solved using the priority attribute at the package level. In the file structure, the priority attribute is a property of the magic matching rule, not of the mimetype. The description in the spec, on the other hand, seems to be relevant to the Mimetype overall: "Low numbers should be used for more generic types (such as 'gzip compressed data') and higher values for specific subtypes (such as a word processor format that happens to use gzip to compress the file)." So does it make sense to use this even when we're not using the magic matching rules? Thanks, Thomas
_______________________________________________ xdg mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/xdg
