Setting unlisted application as a default

Using Fedora Workstation 31. I’ve installed UltraEdit from an RPM package, it’s included in the Settings tool, under “Applications”, but when I try to set it as the default for some file type it’s not listed among the “View All Applications” list.
If I open Settings and select Applications, UltraEdit is listed among the applications. Selecting it shows Default Handlers as “Text Files”, with “plain text document” and “*, v”. No idea what that means, but … is there some other way of setting default applications, even a configuration file hidden somewhere in Fedora I can edit manually?

Identify the MIME type of the file you want to open by default with one of the following commands:

xdg-mime query filetype /etc/profile

Change the default application for the specified MIME type:

xdg-mime default org.gnome.gedit.desktop text/plain

You can use autocomplete to find out the exact application name.


In addition, it is possible to add custom MIME types like this:

tee custom-mime.xml << "EOF" > /dev/null
<?xml version="1.0" encoding="utf-8"?>
<mime-info xmlns="http://www.freedesktop.org/standards/shared-mime-info">
<mime-type type="application/x-batchscript">
<comment>Batch script</comment>
<generic-icon name="text-x-script"/>
<sub-class-of type="application/x-shellscript"/>
<sub-class-of type="text/plain"/>
<glob pattern="*.bat"/>
</mime-type>
</mime-info>
EOF
sudo xdg-mime install --mode system custom-mime.xml
2 Likes

Perfect!! Thanks SO much

1 Like

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.