You are not logged in.
When I have no defaults.list and mimeapps.list, xdg-open opens text/plain with gvim. But when I create defaults.list in /usr/share/applications/ and add the following lines :
[Default Applications]
text/plain=emacs.desktopit opens text files with firefox.
However, if I move /usr/share/applications/defaults.list to ~/.local/share/applications/mimeapps.list, it opens text files with emacs as expected.
What is happening with xdg-open?
Offline