You are not logged in.
I'm currently using KDE Plasma 6. I used to use alacritty as the default terminal emulator, including to open .desktop shortcuts (I don't remember what I did).
I'd like to switch back to Konsole, but I've forgotten what I've done. As a result, things like btop now use alacritty, instead of konsole.
I tried changing the default application back to Konsole in Plasma settings, to no avail. I also tried deleting alacritty but now apps don't run at all.
I tried "xdg-open ~/.bashrc" to see what would happen and I got
kf.service.services: KApplicationTrader: mimeType "x-scheme-handler/file" not found
kf.kio.core: Terminal "alacritty" not found, service "Neovim"
kf.kio.gui: "Terminal alacritty not found while trying to run ~/.local/share/applications/nvim.desktop"
"echo $TERM" returns "xterm-256color" and "echo $TERMINAL" returns "konsole".
Any ideas?
Last edited by A-Fellow-Human (2024-04-01 05:56:23)
Offline
Try to use this: https://wiki.archlinux.org/title/Xdg-utils#xdg-mime
Offline
Try to use this: https://wiki.archlinux.org/title/Xdg-utils#xdg-mime
Try what specifically?
I already had a look at the page before posting but I don't know which MIME type corresponds to the default terminal. I tried "xdg-mime query default application/x-shellscript" but that just points to nvim.
Last edited by A-Fellow-Human (2024-03-27 14:32:56)
Offline
There's a setting for this in KDE's system settings, have you checked that?
Offline
Not sure if it works for Qt desktops but for xdg-open the OP could create a wrapper script at /usr/local/bin/xdg-terminal-exec to launch alacritty, as per the last answer here.
EDIT: and the error message in the OP is because xdg-open is trying to run ~/.local/share/applications/nvim.desktop, which is presumably hard-coded for alacritty. Check for other .desktop files in that directory.
Last edited by Head_on_a_Stick (2024-03-27 19:25:48)
godisnowhere
Offline
for xdg-open the OP could create a wrapper script at /usr/local/bin/xdg-terminal-exec
Which itself is probably on the chopping block already:
https://gitlab.gnome.org/GNOME/glib/-/issues/338
(there're a couple of threads on this forum itr because for a while it was completely impossible to select the default TE on gnome)
In reality, there's no spec - one could have just interpreted $TERMINAL but that's oc way too simple and it's better to have https://imgs.xkcd.com/comics/standards.png
The OP is using KDE so the only reliable approach is V1del's comment.
Online
So I went back to the "Default Applications" settings, switched the terminal emulator to foot, and tried opening btop. That worked.
I then switched back to konsole, and terminal applications use the correct terminal emulator instead of using alaccritty.
Weird bug, but whatever. Thanks seth for convincing me to have a look at the settings page again, because I would've tried to keep doing weird things to get terminal apps working.
Offline