Konsole context menu "Open File Manager" not working

Sadly, that won’t change things for the su - scenario, as there are no KONSOLE_ variables whatsoever available to root, thus is won’t matter which ones the function tries to check.

There is no sadness entered into the equation. This is specifically the scenario I tested for; no error was returned, and the Open File Manager context item worked as expected both before, during and after returning from Super User privileges.

Not strictly a solution but certainly a workaround.

It works for me.™

Actually, there is - the sadness stems from the fact that it seems to be working on your system (which has likely been installed a while ago and updated over time). Just check env on your system after running su -, that should list KONSOLE_ variables (has to for this to work).

On a freshly installed, unmodified Manjaro, it doesn’t work (for reasons already stated). The interesting question is: what is different on your system compared to a fresh install?

Interesting.
I’m testing that via VM as I type (KDE 24 currently installing). I’ll check both before and after a first update.

Initial environment variables
COLORFGBG=15;0
COLORTERM=truecolor
DBUS_SESSION_BUS_ADDRESS=unix:path=/run/user/1000/bus
DEBUGINFOD_URLS=https://debuginfod.archlinux.org 
DESKTOP_SESSION=plasma
DISPLAY=:0
GTK2_RC_FILES=/etc/gtk-2.0/gtkrc:/home/kermit/.gtkrc-2.0:/home/kermit/.config/gtkrc-2.0
GTK3_MODULES=xapp-gtk3-module
GTK_MODULES=canberra-gtk-module
GTK_RC_FILES=/etc/gtk/gtkrc:/home/kermit/.gtkrc:/home/kermit/.config/gtkrc
HOME=/home/kermit
INVOCATION_ID=57d0a67332aa4e6b8be803db92867dec
JOURNAL_STREAM=9:11746
KDE_APPLICATIONS_AS_SCOPE=1
KDE_FULL_SESSION=true
KDE_SESSION_UID=1000
KDE_SESSION_VERSION=6
KONSOLE_DBUS_SERVICE=:1.71
KONSOLE_DBUS_SESSION=/Sessions/1
KONSOLE_DBUS_WINDOW=/Windows/1
KONSOLE_VERSION=240202
LANG=en_GB.UTF-8
LANGUAGE=
LC_ADDRESS=en_AU.UTF-8
LC_IDENTIFICATION=en_AU.UTF-8
LC_MEASUREMENT=en_AU.UTF-8
LC_MONETARY=en_AU.UTF-8
LC_NAME=en_AU.UTF-8
LC_NUMERIC=en_AU.UTF-8
LC_PAPER=en_AU.UTF-8
LC_TELEPHONE=en_AU.UTF-8
LC_TIME=en_AU.UTF-8
LOGNAME=kermit
MAIL=/var/spool/mail/kermit
MANAGERPID=692
MEMORY_PRESSURE_WATCH=/sys/fs/cgroup/user.slice/user-1000.slice/user@1000.service/session.slice/plasma-plasmashell.service/memory.pressure
MEMORY_PRESSURE_WRITE=c29tZSAyMDAwMDAgMjAwMDAwMAA=
MOTD_SHOWN=pam
PAM_KWALLET5_LOGIN=/run/user/1000/kwallet5.socket
PATH=/home/kermit/.local/bin:/usr/local/sbin:/usr/local/bin:/usr/bin:/usr/bin/site_perl:/usr/bin/vendor_perl:/usr/bin/core_perl
PROFILEHOME=
PWD=/home/kermit
QT_AUTO_SCREEN_SCALE_FACTOR=0
QT_LINUX_ACCESSIBILITY_ALWAYS_ON=1
QT_WAYLAND_RECONNECT=1
SESSION_MANAGER=local/kermit-vmware201:@/tmp/.ICE-unix/791,unix/kermit-vmware201:/tmp/.ICE-unix/791
SHELL=/bin/bash
SHELL_SESSION_ID=9970e405e1dd4115b97756c657255b93
SYSTEMD_EXEC_PID=858
TERM=xterm-256color
USER=kermit
WINDOWID=56623128
XAUTHORITY=/tmp/xauth_MiZETL
XDG_CONFIG_DIRS=/home/kermit/.config/kdedefaults:/etc/xdg:/usr/share/manjaro-kde-settings/xdg
XDG_CURRENT_DESKTOP=KDE
XDG_DATA_DIRS=/home/kermit/.local/share/flatpak/exports/share:/var/lib/flatpak/exports/share:/usr/local/share:/usr/share
XDG_MENU_PREFIX=plasma-
XDG_RUNTIME_DIR=/run/user/1000
XDG_SEAT=seat0
XDG_SEAT_PATH=/org/freedesktop/DisplayManager/Seat0
XDG_SESSION_CLASS=user
XDG_SESSION_DESKTOP=KDE
XDG_SESSION_ID=2
XDG_SESSION_PATH=/org/freedesktop/DisplayManager/Session1
XDG_SESSION_TYPE=x11
XDG_VTNR=2
SHLVL=1
OLDPWD=/home/kermit
LESS_TERMCAP_mb=
LESS_TERMCAP_md=
LESS_TERMCAP_me=
LESS_TERMCAP_se=
LESS_TERMCAP_so=
LESS_TERMCAP_ue=
LESS_TERMCAP_us=
LESS=-R
LS_OPTIONS=--color=auto
LS_COLORS=rs=0:di=01;34:ln=01;36:mh=00:pi=40;33:so=01;35:do=01;35:bd=40;33;01:cd=40;33;01:or=40;31;01:mi=00:su=37;41:sg=30;43:ca=00:tw=30;42:ow=34;42:st=37;44:ex=01;32:*.7z=01;31:*.ace=01;31:*.alz=01;31:*.apk=01;31:*.arc=01;31:*.arj=01;31:*.bz=01;31:*.bz2=01;31:*.cab=01;31:*.cpio=01;31:*.crate=01;31:*.deb=01;31:*.drpm=01;31:*.dwm=01;31:*.dz=01;31:*.ear=01;31:*.egg=01;31:*.esd=01;31:*.gz=01;31:*.jar=01;31:*.lha=01;31:*.lrz=01;31:*.lz=01;31:*.lz4=01;31:*.lzh=01;31:*.lzma=01;31:*.lzo=01;31:*.pyz=01;31:*.rar=01;31:*.rpm=01;31:*.rz=01;31:*.sar=01;31:*.swm=01;31:*.t7z=01;31:*.tar=01;31:*.taz=01;31:*.tbz=01;31:*.tbz2=01;31:*.tgz=01;31:*.tlz=01;31:*.txz=01;31:*.tz=01;31:*.tzo=01;31:*.tzst=01;31:*.udeb=01;31:*.war=01;31:*.whl=01;31:*.wim=01;31:*.xz=01;31:*.z=01;31:*.zip=01;31:*.zoo=01;31:*.zst=01;31:*.avif=01;35:*.jpg=01;35:*.jpeg=01;35:*.mjpg=01;35:*.mjpeg=01;35:*.gif=01;35:*.bmp=01;35:*.pbm=01;35:*.pgm=01;35:*.ppm=01;35:*.tga=01;35:*.xbm=01;35:*.xpm=01;35:*.tif=01;35:*.tiff=01;35:*.png=01;35:*.svg=01;35:*.svgz=01;35:*.mng=01;35:*.pcx=01;35:*.mov=01;35:*.mpg=01;35:*.mpeg=01;35:*.m2v=01;35:*.mkv=01;35:*.webm=01;35:*.webp=01;35:*.ogm=01;35:*.mp4=01;35:*.m4v=01;35:*.mp4v=01;35:*.vob=01;35:*.qt=01;35:*.nuv=01;35:*.wmv=01;35:*.asf=01;35:*.rm=01;35:*.rmvb=01;35:*.flc=01;35:*.avi=01;35:*.fli=01;35:*.flv=01;35:*.gl=01;35:*.dl=01;35:*.xcf=01;35:*.xwd=01;35:*.yuv=01;35:*.cgm=01;35:*.emf=01;35:*.ogv=01;35:*.ogx=01;35:*.aac=00;36:*.au=00;36:*.flac=00;36:*.m4a=00;36:*.mid=00;36:*.midi=00;36:*.mka=00;36:*.mp3=00;36:*.mpc=00;36:*.ogg=00;36:*.ra=00;36:*.wav=00;36:*.oga=00;36:*.opus=00;36:*.spx=00;36:*.xspf=00;36:*~=00;90:*#=00;90:*.bak=00;90:*.crdownload=00;90:*.dpkg-dist=00;90:*.dpkg-new=00;90:*.dpkg-old=00;90:*.dpkg-tmp=00;90:*.old=00;90:*.orig=00;90:*.part=00;90:*.rej=00;90:*.rpmnew=00;90:*.rpmorig=00;90:*.rpmsave=00;90:*.swp=00;90:*.tmp=00;90:*.ucf-dist=00;90:*.ucf-new=00;90:*.ucf-old=00;90:
P9K_SSH=0
_P9K_SSH_TTY=/dev/pts/3
P9K_TTY=old
_P9K_TTY=/dev/pts/3
_=/usr/bin/env

Variables seem populated.

  • Error is triggered as expected. Now applying modification to usr/share/zsh/manjaro-zsh-config: The workaround is successful.
  • Will now see if anything in subsequent updates happens to change that; this will take a few minutes; while waiting, I’ll just confirm the branch - on Stable;

The workaround as per @MrLavender was again successful - initially, and after both entering and exiting su -. These results are satisfactory, in as far as I can see.

Perhaps your environment is missing something. :man_shrugging:

Cheers.

That’s weird…

Just to be sure: are we talking about the same setup?

I’m testing with a fresh install of https://download.manjaro.org/kde/24.0.2/manjaro-kde-24.0.2-240611-linux69.iso from Manjaro’s Download page.

That is the same image I used for my production systems (for which I’m trying to come up with a fix for the issue at hand).

Implementing the workaround there works for normal users, but not for root after becoming root using su - (just tested it again to be absolutely sure).

I tested with manjaro-kde-24.0-240513-linux69.iso.

Yes, it’s possible some condition has changed between the two. I’ll download and check 24.0.2-240611 using the same procedure; that should either confirm/deny the issue, or indicate another.

I will remove the marked solution pending the outcome.

Edit:- It looks like someone already did so, without any comment.

Cheers.

Ok, that’s good to know for starters. I’ll download that ISO and check if I can pinpoint the changes.

I did, in order to prevent the thread from closing automatically and due to the fix/workaround not being fully functional at this time.

Would you mind posting a couple of screenshots of how you’re testing and what your results are (similar to the one I posted)?

manjaro-zsh-config seems to be abandoned for more than a year.

New installation (VM) using manjaro-kde-24.0.2-240611-linux69.iso;
SHA256: c910662ecfc4c624ae54a366ae0301c37cf874b730a1ddeb8ba3bbf4eba51f28;

Adhering to your testing strategy; and with requested screenshots provided; in all cases the Open File Manager context item worked as expected, with the workaround applied:

  • Workaround successful - as User
Initial Envars - 240611-env-user
COLORFGBG=15;0
COLORTERM=truecolor
DBUS_SESSION_BUS_ADDRESS=unix:path=/run/user/1000/bus
DEBUGINFOD_URLS=https://debuginfod.archlinux.org 
DESKTOP_SESSION=plasma
DISPLAY=:0
GTK2_RC_FILES=/etc/gtk-2.0/gtkrc:/home/kermit/.gtkrc-2.0:/home/kermit/.config/gtkrc-2.0
GTK3_MODULES=xapp-gtk3-module
GTK_MODULES=canberra-gtk-module
GTK_RC_FILES=/etc/gtk/gtkrc:/home/kermit/.gtkrc:/home/kermit/.config/gtkrc
HOME=/home/kermit
ICEAUTHORITY=/run/user/1000/iceauth_iTzJDQ
INVOCATION_ID=333ff5797fa1436791462a6d895418da
JOURNAL_STREAM=9:12592
KDE_APPLICATIONS_AS_SCOPE=1
KDE_FULL_SESSION=true
KDE_SESSION_UID=1000
KDE_SESSION_VERSION=6
KONSOLE_DBUS_SERVICE=:1.62
KONSOLE_DBUS_SESSION=/Sessions/1
KONSOLE_DBUS_WINDOW=/Windows/1
KONSOLE_VERSION=240500
LANG=en_GB.UTF-8
LANGUAGE=
LC_ADDRESS=en_AU.UTF-8
LC_IDENTIFICATION=en_AU.UTF-8
LC_MEASUREMENT=en_AU.UTF-8
LC_MONETARY=en_AU.UTF-8
LC_NAME=en_AU.UTF-8
LC_NUMERIC=en_AU.UTF-8
LC_PAPER=en_AU.UTF-8
LC_TELEPHONE=en_AU.UTF-8
LC_TIME=en_AU.UTF-8
LOGNAME=kermit
MAIL=/var/spool/mail/kermit
MANAGERPID=792
MEMORY_PRESSURE_WATCH=/sys/fs/cgroup/user.slice/user-1000.slice/user@1000.service/session.slice/plasma-plasmashell.service/memory.pressure
MEMORY_PRESSURE_WRITE=c29tZSAyMDAwMDAgMjAwMDAwMAA=
MOTD_SHOWN=pam
PAM_KWALLET5_LOGIN=/run/user/1000/kwallet5.socket
PATH=/home/kermit/.local/bin:/usr/local/sbin:/usr/local/bin:/usr/bin:/usr/bin/site_perl:/usr/bin/vendor_perl:/usr/bin/core_perl
PROFILEHOME=
PWD=/home/kermit
QT_AUTO_SCREEN_SCALE_FACTOR=0
QT_LINUX_ACCESSIBILITY_ALWAYS_ON=1
QT_WAYLAND_RECONNECT=1
SESSION_MANAGER=local/kermit-vmware201:@/tmp/.ICE-unix/892,unix/kermit-vmware201:/tmp/.ICE-unix/892
SHELL=/bin/bash
SHELL_SESSION_ID=b5893e13ac184d9798ebc7c6f252633a
SYSTEMD_EXEC_PID=978
TERM=xterm-256color
USER=kermit
WINDOWID=4194328
XAUTHORITY=/tmp/xauth_PMKRlp
XDG_CONFIG_DIRS=/home/kermit/.config/kdedefaults:/etc/xdg:/usr/share/manjaro-kde-settings/xdg
XDG_CURRENT_DESKTOP=KDE
XDG_DATA_DIRS=/home/kermit/.local/share/flatpak/exports/share:/var/lib/flatpak/exports/share:/usr/local/share:/usr/share
XDG_MENU_PREFIX=plasma-
XDG_RUNTIME_DIR=/run/user/1000
XDG_SEAT=seat0
XDG_SEAT_PATH=/org/freedesktop/DisplayManager/Seat0
XDG_SESSION_CLASS=user
XDG_SESSION_DESKTOP=KDE
XDG_SESSION_ID=2
XDG_SESSION_PATH=/org/freedesktop/DisplayManager/Session1
XDG_SESSION_TYPE=x11
XDG_VTNR=2
SHLVL=1
OLDPWD=/home/kermit
LESS_TERMCAP_mb=e[01;32m
LESS_TERMCAP_md=e[01;32m
LESS_TERMCAP_me=e[0m
LESS_TERMCAP_se=e[0m
LESS_TERMCAP_so=e[01;47;34m
LESS_TERMCAP_ue=e[0m
LESS_TERMCAP_us=e[01;36m
LESS=-R
LS_OPTIONS=--color=auto
LS_COLORS=rs=0:di=01;34:ln=01;36:mh=00:pi=40;33:so=01;35:do=01;35:bd=40;33;01:cd=40;33;01:or=40;31;01:mi=00:su=37;41:sg=30;43:ca=00:tw=30;42:ow=34;42:st=37;44:ex=01;32:*.7z=01;31:*.ace=01;31:*.alz=01;31:*.apk=01;31:*.arc=01;31:*.arj=01;31:*.bz=01;31:*.bz2=01;31:*.cab=01;31:*.cpio=01;31:*.crate=01;31:*.deb=01;31:*.drpm=01;31:*.dwm=01;31:*.dz=01;31:*.ear=01;31:*.egg=01;31:*.esd=01;31:*.gz=01;31:*.jar=01;31:*.lha=01;31:*.lrz=01;31:*.lz=01;31:*.lz4=01;31:*.lzh=01;31:*.lzma=01;31:*.lzo=01;31:*.pyz=01;31:*.rar=01;31:*.rpm=01;31:*.rz=01;31:*.sar=01;31:*.swm=01;31:*.t7z=01;31:*.tar=01;31:*.taz=01;31:*.tbz=01;31:*.tbz2=01;31:*.tgz=01;31:*.tlz=01;31:*.txz=01;31:*.tz=01;31:*.tzo=01;31:*.tzst=01;31:*.udeb=01;31:*.war=01;31:*.whl=01;31:*.wim=01;31:*.xz=01;31:*.z=01;31:*.zip=01;31:*.zoo=01;31:*.zst=01;31:*.avif=01;35:*.jpg=01;35:*.jpeg=01;35:*.mjpg=01;35:*.mjpeg=01;35:*.gif=01;35:*.bmp=01;35:*.pbm=01;35:*.pgm=01;35:*.ppm=01;35:*.tga=01;35:*.xbm=01;35:*.xpm=01;35:*.tif=01;35:*.tiff=01;35:*.png=01;35:*.svg=01;35:*.svgz=01;35:*.mng=01;35:*.pcx=01;35:*.mov=01;35:*.mpg=01;35:*.mpeg=01;35:*.m2v=01;35:*.mkv=01;35:*.webm=01;35:*.webp=01;35:*.ogm=01;35:*.mp4=01;35:*.m4v=01;35:*.mp4v=01;35:*.vob=01;35:*.qt=01;35:*.nuv=01;35:*.wmv=01;35:*.asf=01;35:*.rm=01;35:*.rmvb=01;35:*.flc=01;35:*.avi=01;35:*.fli=01;35:*.flv=01;35:*.gl=01;35:*.dl=01;35:*.xcf=01;35:*.xwd=01;35:*.yuv=01;35:*.cgm=01;35:*.emf=01;35:*.ogv=01;35:*.ogx=01;35:*.aac=00;36:*.au=00;36:*.flac=00;36:*.m4a=00;36:*.mid=00;36:*.midi=00;36:*.mka=00;36:*.mp3=00;36:*.mpc=00;36:*.ogg=00;36:*.ra=00;36:*.wav=00;36:*.oga=00;36:*.opus=00;36:*.spx=00;36:*.xspf=00;36:*~=00;90:*#=00;90:*.bak=00;90:*.crdownload=00;90:*.dpkg-dist=00;90:*.dpkg-new=00;90:*.dpkg-old=00;90:*.dpkg-tmp=00;90:*.old=00;90:*.orig=00;90:*.part=00;90:*.rej=00;90:*.rpmnew=00;90:*.rpmorig=00;90:*.rpmsave=00;90:*.swp=00;90:*.tmp=00;90:*.ucf-dist=00;90:*.ucf-new=00;90:*.ucf-old=00;90:
P9K_SSH=0
_P9K_SSH_TTY=/dev/pts/1
P9K_TTY=old
_P9K_TTY=/dev/pts/1
_=/usr/bin/env

  • Workaround successful - as Super User
Initial Envars - 240611-env-root
COLORFGBG=15;0
COLORTERM=truecolor
DBUS_SESSION_BUS_ADDRESS=unix:path=/run/user/1000/bus
DEBUGINFOD_URLS=https://debuginfod.archlinux.org 
DESKTOP_SESSION=plasma
DISPLAY=:0
GTK2_RC_FILES=/etc/gtk-2.0/gtkrc:/home/kermit/.gtkrc-2.0:/home/kermit/.config/gtkrc-2.0
GTK3_MODULES=xapp-gtk3-module
GTK_MODULES=canberra-gtk-module
GTK_RC_FILES=/etc/gtk/gtkrc:/home/kermit/.gtkrc:/home/kermit/.config/gtkrc
HOME=/home/kermit
ICEAUTHORITY=/run/user/1000/iceauth_iTzJDQ
INVOCATION_ID=333ff5797fa1436791462a6d895418da
JOURNAL_STREAM=9:12592
KDE_APPLICATIONS_AS_SCOPE=1
KDE_FULL_SESSION=true
KDE_SESSION_UID=1000
KDE_SESSION_VERSION=6
KONSOLE_DBUS_SERVICE=:1.62
KONSOLE_DBUS_SESSION=/Sessions/1
KONSOLE_DBUS_WINDOW=/Windows/1
KONSOLE_VERSION=240500
LANG=en_GB.UTF-8
LANGUAGE=
LC_ADDRESS=en_AU.UTF-8
LC_IDENTIFICATION=en_AU.UTF-8
LC_MEASUREMENT=en_AU.UTF-8
LC_MONETARY=en_AU.UTF-8
LC_NAME=en_AU.UTF-8
LC_NUMERIC=en_AU.UTF-8
LC_PAPER=en_AU.UTF-8
LC_TELEPHONE=en_AU.UTF-8
LC_TIME=en_AU.UTF-8
LOGNAME=kermit
MAIL=/var/spool/mail/kermit
MANAGERPID=792
MEMORY_PRESSURE_WATCH=/sys/fs/cgroup/user.slice/user-1000.slice/user@1000.service/session.slice/plasma-plasmashell.service/memory.pressure
MEMORY_PRESSURE_WRITE=c29tZSAyMDAwMDAgMjAwMDAwMAA=
MOTD_SHOWN=pam
PAM_KWALLET5_LOGIN=/run/user/1000/kwallet5.socket
PATH=/home/kermit/.local/bin:/usr/local/sbin:/usr/local/bin:/usr/bin:/usr/bin/site_perl:/usr/bin/vendor_perl:/usr/bin/core_perl
PROFILEHOME=
PWD=/home/kermit
QT_AUTO_SCREEN_SCALE_FACTOR=0
QT_LINUX_ACCESSIBILITY_ALWAYS_ON=1
QT_WAYLAND_RECONNECT=1
SESSION_MANAGER=local/kermit-vmware201:@/tmp/.ICE-unix/892,unix/kermit-vmware201:/tmp/.ICE-unix/892
SHELL=/bin/bash
SHELL_SESSION_ID=b5893e13ac184d9798ebc7c6f252633a
SYSTEMD_EXEC_PID=978
TERM=xterm-256color
USER=kermit
WINDOWID=4194328
XAUTHORITY=/tmp/xauth_PMKRlp
XDG_CONFIG_DIRS=/home/kermit/.config/kdedefaults:/etc/xdg:/usr/share/manjaro-kde-settings/xdg
XDG_CURRENT_DESKTOP=KDE
XDG_DATA_DIRS=/home/kermit/.local/share/flatpak/exports/share:/var/lib/flatpak/exports/share:/usr/local/share:/usr/share
XDG_MENU_PREFIX=plasma-
XDG_RUNTIME_DIR=/run/user/1000
XDG_SEAT=seat0
XDG_SEAT_PATH=/org/freedesktop/DisplayManager/Seat0
XDG_SESSION_CLASS=user
XDG_SESSION_DESKTOP=KDE
XDG_SESSION_ID=2
XDG_SESSION_PATH=/org/freedesktop/DisplayManager/Session1
XDG_SESSION_TYPE=x11
XDG_VTNR=2
SHLVL=1
OLDPWD=/home/kermit
LESS_TERMCAP_mb=e[01;32m
LESS_TERMCAP_md=e[01;32m
LESS_TERMCAP_me=e[0m
LESS_TERMCAP_se=e[0m
LESS_TERMCAP_so=e[01;47;34m
LESS_TERMCAP_ue=e[0m
LESS_TERMCAP_us=e[01;36m
LESS=-R
LS_OPTIONS=--color=auto
LS_COLORS=rs=0:di=01;34:ln=01;36:mh=00:pi=40;33:so=01;35:do=01;35:bd=40;33;01:cd=40;33;01:or=40;31;01:mi=00:su=37;41:sg=30;43:ca=00:tw=30;42:ow=34;42:st=37;44:ex=01;32:*.7z=01;31:*.ace=01;31:*.alz=01;31:*.apk=01;31:*.arc=01;31:*.arj=01;31:*.bz=01;31:*.bz2=01;31:*.cab=01;31:*.cpio=01;31:*.crate=01;31:*.deb=01;31:*.drpm=01;31:*.dwm=01;31:*.dz=01;31:*.ear=01;31:*.egg=01;31:*.esd=01;31:*.gz=01;31:*.jar=01;31:*.lha=01;31:*.lrz=01;31:*.lz=01;31:*.lz4=01;31:*.lzh=01;31:*.lzma=01;31:*.lzo=01;31:*.pyz=01;31:*.rar=01;31:*.rpm=01;31:*.rz=01;31:*.sar=01;31:*.swm=01;31:*.t7z=01;31:*.tar=01;31:*.taz=01;31:*.tbz=01;31:*.tbz2=01;31:*.tgz=01;31:*.tlz=01;31:*.txz=01;31:*.tz=01;31:*.tzo=01;31:*.tzst=01;31:*.udeb=01;31:*.war=01;31:*.whl=01;31:*.wim=01;31:*.xz=01;31:*.z=01;31:*.zip=01;31:*.zoo=01;31:*.zst=01;31:*.avif=01;35:*.jpg=01;35:*.jpeg=01;35:*.mjpg=01;35:*.mjpeg=01;35:*.gif=01;35:*.bmp=01;35:*.pbm=01;35:*.pgm=01;35:*.ppm=01;35:*.tga=01;35:*.xbm=01;35:*.xpm=01;35:*.tif=01;35:*.tiff=01;35:*.png=01;35:*.svg=01;35:*.svgz=01;35:*.mng=01;35:*.pcx=01;35:*.mov=01;35:*.mpg=01;35:*.mpeg=01;35:*.m2v=01;35:*.mkv=01;35:*.webm=01;35:*.webp=01;35:*.ogm=01;35:*.mp4=01;35:*.m4v=01;35:*.mp4v=01;35:*.vob=01;35:*.qt=01;35:*.nuv=01;35:*.wmv=01;35:*.asf=01;35:*.rm=01;35:*.rmvb=01;35:*.flc=01;35:*.avi=01;35:*.fli=01;35:*.flv=01;35:*.gl=01;35:*.dl=01;35:*.xcf=01;35:*.xwd=01;35:*.yuv=01;35:*.cgm=01;35:*.emf=01;35:*.ogv=01;35:*.ogx=01;35:*.aac=00;36:*.au=00;36:*.flac=00;36:*.m4a=00;36:*.mid=00;36:*.midi=00;36:*.mka=00;36:*.mp3=00;36:*.mpc=00;36:*.ogg=00;36:*.ra=00;36:*.wav=00;36:*.oga=00;36:*.opus=00;36:*.spx=00;36:*.xspf=00;36:*~=00;90:*#=00;90:*.bak=00;90:*.crdownload=00;90:*.dpkg-dist=00;90:*.dpkg-new=00;90:*.dpkg-old=00;90:*.dpkg-tmp=00;90:*.old=00;90:*.orig=00;90:*.part=00;90:*.rej=00;90:*.rpmnew=00;90:*.rpmorig=00;90:*.rpmsave=00;90:*.swp=00;90:*.tmp=00;90:*.ucf-dist=00;90:*.ucf-new=00;90:*.ucf-old=00;90:
P9K_SSH=0
_P9K_SSH_TTY=/dev/pts/1
P9K_TTY=old
_P9K_TTY=/dev/pts/1
_=/usr/bin/env
Workaround successful - on return from SU

These results again show confidence in the workaround offered by @MrLavender.

Edit:- Included screenshots will be deleted after the OP has acknowledged this post.


I’m not sure how relevant that might be; presuming the same version of the script is in play in all test cases, one would expect to have the same results.

As contributors to manjaro-zsh-config perhaps @pheiduck or @Yochanan might have some input of possible benefit to the OP.


With respect the workaround, all I can offer is – it works for me.™

Please do not post screenshots unless absolutely necessary. Text is preferred.

You have declared the function inside a clean root login shell. It’s not going to work there because graphical DE environment variables aren’t set. Declare it before using su - or put it in your .zshrc.

I requested those for a reason, to verify a hypothesis:
The screenshots show that root on the @soundofthunder’s machine is not using zsh, but bash, which I presumed. The issue only arises when root uses zsh.

Thanks, but I’m aware of that, I stated that in one of my previous posts.

Thank you, now it’s clear why we came to different conclusions - root on your machine uses bash as its shell, not zsh. The issue only arises if zsh is being used (see my screenshot posted here).

Well, now it’s back to square one. One viable solution is to clear URL_HOST unconditionally, i.e. don’t check for any KONSOLE_ variables at all. Probably the best approach for now until this gets resolved upstream.

On a freshly installed and unmodified Manjaro KDE installation, bash must then be used by root; why does it not on your default install(s)? :man_shrugging:

I typically set bash as the global default (long-standing habit), but not so in these instances.

Of course when manually set to zsh, the result is unfavourable;

As you say, square one…

Screenshot deleted.

1 Like

It is, which actually is a weird choice by Manjaro in and of itself (zsh for user, bash for root that is), but that is beside the point.

You were so adamant regarding the effectiveness of the workaround that I falsely assumed we were talking about the same thing. Also, the default prompts used by zsh vs. bash are so distinctive that it just never crossed my mind that one might confuse the two of them. It only dawned on me when I tried the ISO you mentioned myself and was unable to reproduce your results.

I should have been more clear in that regard, i.e. fresh, unmodified install + chsh -s /usr/bin/zsh for root.

An obvious resolve is to not use zsh as the Super User at all.

Pondering…

I’m aware that some distributions (still) have an Open as Root (or similar) context menu entry (usually available via a plugin) in their file managers. This has become frowned upon for a number of years despite the convenience it appears to offer.

As I understand it, in Manjaro, there is no valid reason to open Dolphin as root. Perhaps the Open File Manager context item should be disabled completely while in a Super User session. :thinking:

True. Such an entry is quite useful, but frowned upon since it usually runs the terminal program itself as root (e.g. Konsole), which is not at all desirable. On my systems, I usually add an entry that runs the terminal program as a normal user, but opens a root shell once it has started up (e.g. konsole -e su).

The context menu item won’t start the file manager as root, as it is Konsole that does the starting (which runs with user privileges), not the shell inside.

  1. The solution I posted works on a default Manjaro KDE install (and on the live ISO).

  2. Even so, a root login shell is not intended for that kind of work. There is a reason why it knows nothing about any graphical environment that it might be running in. If you want an interactive root shell use su.

  3. bash is the standard root shell on nearly every Linux distro. User accounts are free to use whatever they like but messing with the root account is a bad idea and is unsupported. See also Why shouldn’t I install Oh My Zsh as root? (manjaro-zsh-profile is based on Oh My Zsh).

  4. It’s your system and you’re free to do what you like and ignore all the above. In that case you’re the support.

What I meant is that Manjaro should also apply the fixes done by “Oh My Zsh” to their forked and outdated manjaro-zsh-config.

Ah, I see. Yes, that makes sense.