0

I am often opening terminal app in opened directory (in Nautilus on Ubuntu 22.04) with the context menu and its option "Open in terminal", but in this case, the terminal app is opened and not konsole app, which is set as default.

See the output of the command: sudo update-alternatives --config x-terminal-emulator

result of command as picture

When I used keyboard shorcut Ctrl + Alt + T, Konsole opens as expected. So Only this context option is not working as I expected. Is there any way how to reconfigure it?

4 Answers 4

0

I found this answer, tried it myself and found out that the package name and installation has changed.(Ubuntu 20.04)

The package is now called filemanager-actions and there is a necessary nautilus extension called nautilus-extension-fma, so to install;

sudo apt install filemanager-actions nautilus-extension-fma

After installing these packages, open filemanager-actions from applications menu, follow the steps on the linked answer (in order to open Konsole, you'll need to replace "/usr/bin/terminator" with "/usr/bin/konsole"), restart nautilus via nautilus -q on a terminal, and you'll be able to open a konsole session from selected directory.

1
  • It seems, these packages are obsolete and not exists for 22.04. But I see where is the problem - "Open in terminal" command is added as part of plugin for Nautilus. There is no plugin for konsole as far I know. So I keep as it for now most probably, thanks anyway. I tried to vote +1 for your answer, but since I am newbie here, I am not able to do so.
    – Kuba
    Aug 1, 2022 at 17:46
0

I found another solution, I hope this works on Ubuntu 22.04 too.

You'll need to create a script file in /home/$USER/.local/share/nautilus/scripts. The name of the file is not important, you can choose whatever you want. For simplicity, I'll go with "konsole".

  1. Create a file in ~/.local/share/nautilus/scripts/ called konsole.
  2. Edit the file with your choice of text editor and copy these lines
#!/bin/bash

directory="$(pwd | sed 's/[ ]/\ /g')"
konsole --workdir "$directory"

(sed part makes possible opening a directory that has spaces in its name)

  1. Make the file executable
chmod +x ~/.local/share/nautilus/scripts/konsole
  1. In order to start the script, you'll need to right-click on any file/folder located in the desired directory, then you'll see an option "scripts" and in that submenu there will be your script.
0

This maybe slightly off topic, but may help someone get the "Open in Terminal" back....

To get the context menu "Open in Terminal" back after upgrading to 22.04 I had to do the following: sudo apt install nautilus-extension-gnome-console

nautilus -q

On opening the filemanager again, I now have right click option to "Open in Terminal"

0

The solution provided by AreaEuro worked pretty fine, but as I wanted my gnome-terminal I did this also:

sudo apt install nautilus-extension-gnome-terminal

and of course I also ran:

nautilus -q

Now I have both in the contextual menu of Nautilus (also called Files in Ubuntu).

Contextual menu in Nautilus:

Screenshot of my contextual menu in Nautilus

1
  • As it’s currently written, your answer is unclear. Please edit to add additional details that will help others understand how this addresses the question asked. You can find more information on how to write good answers in the help center.
    – Community Bot
    Feb 16 at 7:05

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.