Summary: | xdg-mime/xdg-open does not follow mime-actions-spec | ||
---|---|---|---|
Product: | Portland | Reporter: | Vladimir <vovik-wfa> |
Component: | xdg-utils | Assignee: | Portland Bugs <portland-bugs> |
Status: | RESOLVED MOVED | QA Contact: | |
Severity: | major | ||
Priority: | high | CC: | ignorantguru, pva |
Version: | 1.1.0 rc1 | ||
Hardware: | Other | ||
OS: | Linux (All) | ||
Whiteboard: | |||
i915 platform: | i915 features: |
Description
Vladimir
2012-10-24 12:36:59 UTC
What desktop environment are you using? xdg-utils leverages DE-specific utilities to query/set this stuff, when they are available, for example, under KDE uses: ktraderclient That said, looks like the current code only groks [Default Applications] section of mimeapps.lst I use plain openbox, therefore xdg-open goes through open_generic function. No non-standard DE-specific association exceptions should apply. Agreed, this is generating confusion and incompatibility with the spec being one way and xdg-open handling it in another way. Hi! any news on this? For me personally, if there was news, I'd post notice about it here. I haven't had any time to implement this feature in the generic functions. The generic functions *do* implement this functionality. The `xdg-mime` utility knows how to deal with mimeapps.list but does it incorrectly. It uses a `[Default Applications]` header not covered in the specification rather than the proper `[Added Associations]` section. The fix is as easy as a quick search and replace of two strings. Re-reading http://standards.freedesktop.org/mime-apps-spec/mime-apps-spec-1.0.html today. Important bits: --------------------------- Default Application Indicating the default application for a given mimetype is done by writing into the group [Default Applications] in the file mimeapps.list. The [Default Applications] group indicates the preferred application for a given mimetype. --------------------------- --------------------------- Adding/removing associations Adding and removing associations between mimetypes and applications is done with the following syntax in the mimeapps.list file: [Added Associations] mimetype1=foo1.desktop;foo2.desktop;foo3.desktop mimetype2=foo4.desktop [Removed Associations] mimetype1=foo5.desktop --------------------------- --------------------------- Application ordering The suggested algorithm for listing the applications associated to a given mimetype is: add any "Default Applications" and then "Added Associations" in the first mimeapps.list ... --------------------------- So looks like this has been clarified since the bug was filed, and that all of: [Default Applications] [Added Associations] [Removed Associations] need to be taken into account, highlighting that the xdg-open generic algorithm definitely needs work to comply. Given the looming (and hopefully soon) release of xdg-utils-1.1.0 (final), I personally won't have the time or interest in the short-term to implement this properly, and until it is implemented, I'm seriously considering making the existing open_generic code be a last-ditch fallback, and prefer (and strongly recommend) a better implementation be present and used instread, including: gvfs-open kde-open and possibly even others: gnome-open mate-open exo-open -- GitLab Migration Automatic Message -- This bug has been migrated to freedesktop.org's GitLab instance and has been closed from further activity. You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.freedesktop.org/xdg/xdg-utils/issues/61. |
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.