3

I use Ubuntu MATE 16.04 Xenial Xerus (MATE verison 1.12) and when I right click on a .desktop file with caja there isn't any 'Open With Other Application' option, which is very annoying since I need to open pluma and open the file from there every time i need to edit more things that just the command (the command can be edited with right click->properties) of a .desktop file. Any idea on how i can fix this (if it's a bug) or how i can manually add the 'Open With Other Application' entry (if it's suppose not to be there due to creator's choice)?
Edit:
Adding a custom script as described by pomsky is a great solution. Although, I see that when you right-click some files have an 'Open With Other Application' entry and some others (like .xml) have an 'Open With' entry and then you choose 'Other Application'. Is there any way to add something similar for .desktop files. Maybe by editing something in /usr/share/caja folder? I see some 'open with' code at /usr/share/caja/ui/caja-directory-view-ui.xml but i can't understand it.

1 Answers1

4

You may try this not-so-elegant workaround:

  1. Go to the directory ~/.config/caja/scripts/.
  2. Create an empty document, name it Open-with-Pluma.
  3. Open the document and enter the following two lines:

    #!/bin/sh
    pluma $CAJA_SCRIPT_SELECTED_URIS
    
  4. Save & close the document and mark as executable.

  5. Log out and log in again.

Now you should see an extra item called Scripts in the context menu (right-click menu). There you will find this Open-with-Pluma option which should be working as expected.

pomsky
  • 70,557