xdg-utils: How to handle audio CDs?

Jerome Leclanche adys.wh at gmail.com
Tue Oct 2 08:12:57 PDT 2012


Vincent,

In python-mime, I integrated both defaults.list and mimeinfo.cache:
https://github.com/Adys/python-xdg/blob/master/xdg/actions.py#L119

I remember going through the spec and kind of having to take decisions in
its stead; is the ordering I have reasonable? (See the comment)


J. Leclanche


On Tue, Oct 2, 2012 at 3:48 PM, Vincent Untz <vuntz at gnome.org> wrote:

> Le mardi 02 octobre 2012, à 16:29 +0200, Paul Menzel a écrit :
> > Am Dienstag, den 02.10.2012, 16:14 +0200 schrieb Vincent Untz:
> > > Le lundi 01 octobre 2012, à 10:18 +0200, Paul Menzel a écrit :
> > > > Even adding `x-scheme-handler/cdda` to the desktop file
> > > >
> > > >     $ grep MimeType /usr/share/applications/rhythmbox-device.desktop
> > > >
> MimeType=x-content/audio-player;x-content/audio-cdda;x-scheme-handler/cdda;
> > > >
> > > > and updating the MIME database
> > > >
> > > >     $ sudo update-mime-database /usr/share/mime/
> > >
> > > I think you need to call update-desktop-database, not
> > > update-mime-database.
> >
> > Thanks, but still no luck.
> >
> >         $ grep cdda /usr/share/applications/rhythmbox-device.desktop
> >
> MimeType=x-content/audio-player;x-content/audio-cdda;x-scheme-handler/cdda;
> >         $ update-desktop-database
> >         Warning in file "/usr/share/applications/pcmanfm.desktop": usage
> of MIME type "x-directory/normal" is discouraged ("x-directory" is an old
> media type that should be replaced with a modern equivalent)
> >         Warning in file "/usr/share/applications/gnumeric.desktop":
> usage of MIME type "zz-application/zz-winassoc-xls" is discouraged
> ("zz-application/zz-winassoc-xls" should be replaced with
> "application/vnd.ms-excel")
> >         The databases in [/usr/local/share/applications,
> /usr/share/applications] could not be updated.
> >         $ xdg-mime query default "x-scheme-handler/cdda"
> >         $ sudo update-desktop-database
> >         Warning in file "/usr/share/applications/pcmanfm.desktop": usage
> of MIME type "x-directory/normal" is discouraged ("x-directory" is an old
> media type that should be replaced with a modern equivalent)
> >         Warning in file "/usr/share/applications/gnumeric.desktop":
> usage of MIME type "zz-application/zz-winassoc-xls" is discouraged
> ("zz-application/zz-winassoc-xls" should be replaced with
> "application/vnd.ms-excel")
> >         $ xdg-mime query default "x-scheme-handler/cdda"
> >         $
>
> Ah, right, xdg-mime looks at /usr/share/applications/defaults.list, and
> how this file is updated actually depends on the distro. This is
> unfortunately not covered by any spec.
>
> That being said, xdg-mime should probably fall back to looking at the
> content of /usr/share/applications/mimeinfo.cache and take one .desktop
> file from there if the mime type is present in there.
>
> This is https://bugs.freedesktop.org/show_bug.cgi?id=31629
>
> Cheers,
>
> Vincent
>
> --
> Les gens heureux ne sont pas pressés.
> _______________________________________________
> xdg mailing list
> xdg at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/xdg
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/xdg/attachments/20121002/46ac431c/attachment.html>


More information about the xdg mailing list