Page 1 of 1
Running XFCE without Thunar - replaced it with PCmanFM
Posted: Sun Nov 27, 2022 3:16 am
by bpr323
I fully replaced Thunar with PCManFM and uninstall Thunar altogether. Everything running smoothly.
https://blog.desdelinux.net/en/reemplaz ... m-en-xfce/
Re: Running XFCE without Thunar - replaced it with PCmanFM
Posted: Sun Nov 27, 2022 3:20 am
by bpr323
Here's how to run PCMANFM as ROOT:
1) Create xsudo file: touch xsudo
2) Make it executable: chmod +x xsudo
3) Insert this:
#!/bin/bash
if [ -z $1 ]; then
echo -e "at least 1 argument required!\n" >> /dev/stderr
exit 1
fi
COMMAND=$1
shift #shift first arg
for ARG in "$@"
do
if [ -z "$ARGS" ]; then
ARGS="$ARG"
else
ARGS="$ARGS $ARG"
fi
done
ARGS=\'$ARGS\'
eval pkexec env DISPLAY=$DISPLAY XAUTHORITY=$XAUTHORITY $COMMAND $ARGS
exit 0
=======================================================================
=> sudo pcmanfm
4) Place the "xsudo" file into /usr/bin/
5) Create folder/s: -> /home/me/.local/share/file-manager/actions/
6) Create file: OpenFolderAsRoot.desktop
###########################
[Desktop Entry]
Type=Action
Tooltip=Open Folder As Root
Name=Open Folder As Root
Profiles=profile-zero;
Icon=gtk-dialog-authentication
Exec=/usr/bin/xsudo /usr/bin/pcmanfm %u
[X-Action-Profile profile-zero]
MimeTypes=inode/directory;
Exec=/usr/bin/xsudo /usr/bin/pcmanfm %u
Name=Default profile
############################
Re: Running XFCE without Thunar - replaced it with PCmanFM
Posted: Sun Nov 27, 2022 2:44 pm
by Buck Fankers
Nice guide, thanks for sharing!
Re: Running XFCE without Thunar - replaced it with PCmanFM
Posted: Sun Nov 27, 2022 3:26 pm
by wdscharff
Of course, you can also make it easy for yourself ...
This is what my entry in the root menu of Fluxbox looks like:
Code: Select all
[exec] (PCManFM file manager as root) {gksu pcmanfm} </home/winnI/.fluxbox/fbmenugen/icons/31da3d0273cb377eba2bd0f9c5e9562d.png>
I also have a *.desktop file from the past somewhere, but I can't find it at the moment :)
Re: Running XFCE without Thunar - replaced it with PCmanFM
Posted: Sun Nov 27, 2022 3:54 pm
by Buck Fankers
wdscharff wrote: Sun Nov 27, 2022 3:26 pm
Of course, you can also make it easy for yourself ...
Code: Select all
[exec] (PCManFM file manager as root) {gksu pcmanfm} </home/winnI/.fluxbox/fbmenugen/icons/31da3d0273cb377eba2bd0f9c5e9562d.png>
Even better
Re: Running XFCE without Thunar - replaced it with PCmanFM
Posted: Sun Nov 27, 2022 4:52 pm
by bpr323
My post was about how to get rid of Thunar completely without loosing XFCE.
If you leave Thunar installed it makes a mess of default file manager actions.
Running PCMAnFM as root is secondary technicality
Re: Running XFCE without Thunar - replaced it with PCmanFM
Posted: Mon Nov 28, 2022 12:34 am
by wdscharff
Why should you lose xfce?
I faintly remember that under MX17 oder MX18, when you uninstalled Thunar, parts of XFCE were removed, or when you removed Tumbler (which is much more annoying than Thunar), Thunar was removed as a dependency.
I think this was no longer an issue under MX19 and not with MX21 either. So why remove it at all? I've been using pcmanfm since the blessed days of opensuse 10.x (pcmanfm was still very fresh, new back then), but I never uninstalled the file manager that belonged to the respective desktop environment. Because of the 10MB of hard disk space you gain?
If it's about space, then you remove superfluous language files, themes, wallpapers, icon sets and then we're not rid of 10MB, but over 1GB.
Of course the purely technical aspect is interesting, I just don't know if the effort is in proportion to the benefit (apart from the learning aspect).
admittedly, I don't know what the current situation is with MX21, I use MX21/fluxbox and pcmanfm (and 4pane, xfe, double commander, etc ... and Thunar is also somewhere).
Re: Running XFCE without Thunar - replaced it with PCmanFM
Posted: Mon Nov 28, 2022 6:12 am
by bpr323
If you use Fluxbox (or Openbox) window manager, then Thunar, of course, is just another FM that has absolutely no bearing on your DE ...
However, XFCE cannot operate w/o Thunar - if you "just" remove it, XFCE DE will cease to exist.
I like the XFCE panel, App menu (not Whisker) and widgets, but I like PCMAnFM more, so the effort described in my post goes to "have the pie and eat it" - a bit like Windows 11 w/o Edge and Defender :)
Re: Running XFCE without Thunar - replaced it with PCmanFM
Posted: Mon Nov 28, 2022 6:51 am
by bpr323
Feel free to try out my Thunar-less MX-21 xfce ahs snapshot for a change :)
https://gofile.io/d/ipk118
username = me
root pwd = xxx
Re: Running XFCE without Thunar - replaced it with PCmanFM
Posted: Mon Nov 28, 2022 7:38 am
by Huckleberry Finn
In fact
gksu was deprecated (though it still looks still installed)
You can use
mx-pkexec instead.
Also this is possible:
(... or the path you like as the default, i.e.
pcmanfm admin:///etc/.../... )
however you need to be careful as the theme is the same as user's and there's no warning like "You are using the root instance blah blah..."
Re: Running XFCE without Thunar - replaced it with PCmanFM
Posted: Mon Nov 28, 2022 7:48 am
by wdscharff
bpr323 wrote: Mon Nov 28, 2022 6:51 am
Feel free to try out my Thunar-less MX-21 xfce ahs snapshot for a change :)
sorry, no, i don't have to look at it. Would still be an XFCE only without Thunar. And Thunar was not one of the reasons why I switched to Fluxbox.
I simply lack curiosity and time, especially considering that I don't learn anything new for my needings there.
Just as you like the xfce panel and app menu, I like the Fluxbox root menu, Tint2 and Rofi, although I have also used tint2 under xfce as a replacement for the xfce panel ;-}
Re: Running XFCE without Thunar - replaced it with PCmanFM
Posted: Mon Nov 28, 2022 7:54 am
by wdscharff
Huckleberry Finn wrote: Mon Nov 28, 2022 7:38 am
In fact
gksu was deprecated (though it still looks still installed)
Thank you, since gksu is installed, it didn't occur to me that it was outdated.
Already exchanged the command line :-)
Re: Running XFCE without Thunar - replaced it with PCmanFM
Posted: Mon Nov 28, 2022 9:09 am
by dolphin_oracle
on mx, gksu is a symlink to mx-pkexec, which uses policykit.
Re: Running XFCE without Thunar - replaced it with PCmanFM
Posted: Mon Nov 28, 2022 9:16 am
by Huckleberry Finn
In fact, I knew (remember) it like that. What misguided me is that when I checked it looked like a normal file.. However I now see that it's within the (gksu) script:
...
exec mx-pkexec "$@"
Re: Running XFCE without Thunar - replaced it with PCmanFM
Posted: Mon Nov 28, 2022 9:18 am
by dolphin_oracle
my memory bad :)
I forgot it was adjusted to be able to handle some command line switches that gksu had. it used to be a symlink.
Re: Running XFCE without Thunar - replaced it with PCmanFM
Posted: Mon Nov 28, 2022 9:19 am
by Huckleberry Finn
No :) .. just .. another way of link :)