re: comment #15 In Kubuntu 16.04, xdg-open is a bash script that determines your desktop environment (starting with the value of $XDG_CURRENT_DESKTOP) and calls the file opener for that desktop. For XFCE that appears to be exo-open. So run exo-open in debug mode to see what's going on.
> xdg-mime query default application/x-desktop This outputs "wine-extension-txt.desktop" in my Kubuntu 16.04 desktop, so `xdg-open /path/to/some.desktop` grinds away and eventually starts Notepad in Wine! After I renamed $HOME/.local/share/applications/wine- extension-txt.desktop to ..._DISABLED, that command outputs "org.kde.kate.desktop" and so the file opens in the Kate editor. As I understand it, our desktops don't have a .desktop file volunteering to handle the mime type application/x-desktop. The `/usr/share/mime/application/x-desktop.xml` file that associates the extension .desktop file with application/x-desktop also says it's <sub- class-of type="text/plain"/>, and that's why desktops end up running the application that handles text files. -- You received this bug notification because you are a member of Desktop Packages, which is subscribed to gvfs in Ubuntu. https://bugs.launchpad.net/bugs/378783 Title: xdg-open *.desktop opens text editor Status in gvfs: Confirmed Status in gvfs package in Ubuntu: Confirmed Bug description: Binary package hint: xdg-utils In order to reproduce it execute "xdg-open *.desktop" (choose any .desktop file, e.g. one from /usr/share/applications). Actually your favorite text editor will open the file. Expected result: It'll be executed. Because of this bug, desktop entries with the new "#!/usr/bin/env xdg- open" shebang feature were opened in the text editor when executed from command line. To manage notifications about this bug go to: https://bugs.launchpad.net/gvfs/+bug/378783/+subscriptions -- Mailing list: https://launchpad.net/~desktop-packages Post to : [email protected] Unsubscribe : https://launchpad.net/~desktop-packages More help : https://help.launchpad.net/ListHelp

