By default (on a double-click action), my GUI file manager (nemo) runs a text editor, for all files of mimetype=text/plain.

I currently have a user text file gnuplot.speedtest (with mimetype text/plain), which I'd like to treat differently, by running gnuplot instead.

Obviously, I still want the standard default to apply to all other text files.

  • The necessary steps appear to be:- 1. Create a new mime-type such as application/x-gnuplot by writing an appropriate XML file which applies to filenames of the form '*.gnuplot'. This will require the filename in the question to be changed to 'speedtest.gnuplot' 2. Create a userapp-gnuplot.desktop file to associate the mime-type with the gnuplot program. 3. Somewhere it will be possible to associate an icon with this mime-type [optional]. Commented Jan 11, 2021 at 2:02

1 Answer 1


With Caja (who is afaik, a fork of nemo) :

To select a program to open the file, right click and select 'Open with..'

To change list: right-click file name, then 'properties', then tab 'Open with', eventually then 'Add', then select default program in list.

  • 1
    This would associate all files of mimetype=text/plain with the selected program, not those whose filenames e.g. match the pattern "starting with 'gnuplot.'"
    – mYnDstrEAm
    Commented Jan 10, 2021 at 16:36

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .