Ubuntu's gui "Open With" command is not memorizing the application

Mine never did remember settings when set via the Nautilus "open with" dialog. (I was trying to make VLC my default player for various video filetypes -- AVI, etc -- and it never stuck.)

I eventually got the setting to stick using Ubuntu Tweak's File Type Manager.

sudo add-apt-repository ppa:tualatrix/ppa

sudo aptitude update

sudo aptitude install ubuntu-tweak

Afterwards, Ubuntu Tweak should be available in your Gnome menu: Applications > System Tools > Ubuntu Tweak. Select File Type Manager in the left-hand column, select a filetype category, select a filetype, click the Edit button. There you can select from your system's known choices, or use Add to add a new choice or custom command.


See Adding MIME Types in the Ubuntu Help pages. To make a new MIME type, you can simply add the type to /etc/mime.types and the icon to /usr/share/icons/gnome/*/mimetypes (put SVGs in ...gnome/scalable/mimetypes, and PNGs in the size directories).

There seems to be a way to make this slightly more automatic via XDG. You can use the xdg-mime command to query what your system knows about MIME types and add new ones. See man xdg-mime; install the xdg-utils package if you don't have this command.

If your PPF files are just plain text, you might be able to get away with adding "ppf" to the existing text/plain definition in /etc/mime.types:

text/plain                  asc txt text pot brf ppf

Right-click the document icon in nautilus, then choose Properties | Open With. This will allow you to choose the default application to launch it with, as well as modify the applications that show by default in the context menu of documents of that type.


I was having this trouble until I noticed that my boot partition was full and cleared some space. It was interesting - I released a few tens of megabytes and that freed up the system enough to work and then it somehow released more than a gigabyte on that partition that it was holding for some reason or another. Whew.