You are not logged in.

#1 2019-06-08 00:06:37

TarsolyGer
Member
From: Korea
Registered: 2019-05-19
Posts: 73

[Solved] Can't set default terminal emulator to urxvt on Budgie/Gnome3

Dear fellow users,

I have recently installed Arch Linux with the Budgie Desktop, and for file manager I use Nemo, for terminal emulator, I use urxvt.

I have managed to set up the default terminal for the Nemo file manager (for the right-click option of "Open in Terminal") using gsettings as suggested in the Arch wiki:

gsettings set org.cinnamon.desktop.default-applications.terminal exec urxvt
gsettings set org.cinnamon.desktop.default-applications.terminal exec-arg -e 

This works perfectly for the file manager, it works for the "Open in Terminal" context menu, and it also brings up urxvt if I double click a bash script in Nemo, and runs the script just fine.

So I also tried to set the same defaults for the desktop for the default application using:

gsettings set org.gnome.desktop.default-applications.terminal exec urxvt
gsettings set org.gnome.desktop.default-applications.terminal exec-arg -e 

but this doesn't work.

I have vim in the Budgie menu, and in the relevant part of the vim.desktop file defines the executable and that it should be run in the terminal:

Exec=vim %F
Terminal = true

but clicking on the menu item in the Budgie menu vim doesn't open (nothing happens). Interestingly enough if I change the relevant part of vim.desktop file to

Exec=urxvt -e vim %F
Terminal = false

runs vim in a new urxvt window. It seems that urxvt is just fine, but for some reason the Budgie menu doesn't follow what's set up in the gsettings for the gnome desktop.

Does anyone have some idea on this?

*** EDIT ***
I have installed the gnome-terminal package, and now if I start vim with the original desktop icon in the Budgie menu, it opens vim in the Gnome terminal, even though the gsettings org.gnome.desktop.default-applications.terminal exec setting has not changed. So it seems like the Budgie desktop gets its default terminal emulator from somewhere else.

Thank you in advance.

Last edited by TarsolyGer (2019-06-25 10:19:53)


The only way... is all the way!

Offline

#2 2019-06-24 22:29:16

flortsch
Member
From: Linz, Austria
Registered: 2015-07-21
Posts: 39
Website

Re: [Solved] Can't set default terminal emulator to urxvt on Budgie/Gnome3

The gsettings option for the default terminal application is deprecated in recent Gnome versions.
Don't ask me why, but Gnome unfortunately uses a hard-coded list of terminal applications that it checks for launching.
See here: https://gitlab.gnome.org/GNOME/glib/blo … pappinfo.c

I also stumbled upon this recently with the vim launcher.
I fixed this issue for me by not installing gnome-terminal, but linking /usr/bin/gnome-terminal to my favorite terminal application.

Offline

#3 2019-06-25 02:43:31

TarsolyGer
Member
From: Korea
Registered: 2019-05-19
Posts: 73

Re: [Solved] Can't set default terminal emulator to urxvt on Budgie/Gnome3

flortsch wrote:

The gsettings option for the default terminal application is deprecated in recent Gnome versions.
Don't ask me why, but Gnome unfortunately uses a hard-coded list of terminal applications that it checks for launching.
See here: https://gitlab.gnome.org/GNOME/glib/blo … pappinfo.c

I also stumbled upon this recently with the vim launcher.
I fixed this issue for me by not installing gnome-terminal, but linking /usr/bin/gnome-terminal to my favorite terminal application.

Wow, thank you, I'll try that when I get home. The question what remains is, that even if I link it to /usr/bin/gnome-terminal, won't there be a problem, that while gnome-terminal uses the -x argument, urxvt uses the -e argument? What can I do about that?


The only way... is all the way!

Offline

#4 2019-06-25 08:41:18

flortsch
Member
From: Linz, Austria
Registered: 2015-07-21
Posts: 39
Website

Re: [Solved] Can't set default terminal emulator to urxvt on Budgie/Gnome3

If you look into the code starting at line 2520, you see that depending on which terminal application is found on the path, the code appends either -x, or -e as an argument before launching.
So you could, e.g., if you use urxvt, link urxvt into /usr/bin/ to one of the terminal applications starting at line 2532, i.e., nxterm, color-xterm, rxvt, or dtterm.
It's a hack, but afaik, there is no better solution to this problem in Gnome up to date.

Last edited by flortsch (2019-06-25 08:44:48)

Offline

#5 2019-06-25 10:18:36

TarsolyGer
Member
From: Korea
Registered: 2019-05-19
Posts: 73

Re: [Solved] Can't set default terminal emulator to urxvt on Budgie/Gnome3

Thank you, this worked!
So, for posterity, I did the following:

$ cd /usr/bin
$ sudo ln -s urxvt rxvt

and this little hack does the trick, now the command line applications run from the Budgie menu.

Last edited by TarsolyGer (2019-07-08 14:26:43)


The only way... is all the way!

Offline

Board footer

Powered by FluxBB