2

I'm afraid my question's gonna look like a rant, but I'm really curious how such terrible setting have got created.

According to this answer, any customizations that you make are stored in your home directory, in ~/.local/share/applications/mimeapps.list. However I've found there the following (list shortened and sorted for clarity):

application/x-shellscript=userapp-emacsclient-ETH68V.desktop;emacs23.desktop;gedit.desktop;openoffice.org-writer.desktop;userapp-thunderbird-5IXU8V.desktop;...;userapp-emacsclient-4DBR8V.desktop;writer.desktop;userapp-thunderbird-5IXU8V.desktop;

text/x-sql=emacs23.desktop;userapp-emacsclient-ETH68V.desktop;gedit.desktop;openoffice.org-writer.desktop;userapp-thunderbird-    video/mp4=totem.desktop;vlc.desktop;

video/mpeg=vlc.desktop;
video/x-flv=vlc.desktop;
video/x-matroska=totem.desktop;vlc.desktop;
video/x-ms-wmv=totem.desktop;vlc.desktop;
video/x-msvideo=vlc.desktop;
  • Why is emacsclient twice there? These entries are supposed to be user-defined, but I'm sure I didn't create them. Nor did I ever reinstalled emacs (which could possibly explain this duplicity).

  • Does anybody think openoffice.org-writer should get used for editing shell scripts? Or even Thunderbird? Moreover, it's twice there. It wasn't me, I'm sure.

  • Why does video get associations depending on it's format? Can't I specify something like video/*=vlc.desktop (possibly with exceptions for strange formats my favorite player is incapable to play)?

2 Answers2

1

In my experience using the default applications section in System settings > Details > Default applications isn't all that reliable for some reason that I can't figure out, but Nautilus->RightClick->Open with->SetAsDefault works every time

Jayo
  • 1,241
0

First, if you did not make those connections than someone was in your account and made those connections. Please note however, that "make a connection" does not mean that you edited that file. It means e.g. that you chose to open something via Nautilus->RightClick->Open with... Those are not provided by Ubuntu as you know, since you quoted the answer from the other askubuntu question. The Ubuntu defaults are here: /usr/share/applications/defaults.list.

Second, there is a good reason to have different applications for different video types: some players can not play all types, but still be the preferred application if they are able to.

In general, I would not advice you to edit that file, but follow one of those steps:

  1. System settings > Details > Default applications should open something like this: enter image description here Here you can change the preferred applications for important summary mime types.
  2. Use the freedesktop.org utility xdg-mime to specify an application for a specific mime type: xdg-mime default myapp.desktop mymimetype (replace myapp.desktop and mymimetype with whatever you need)
  3. Or of cause use the right click menu from Nautilus as you already know:Nautilus->RightClick->Open with..
xubuntix
  • 5,580