8

Apologies if this seems straight forward but I've recently downloaded XFCE to replace LXDE environment.

I did this by using

sudo apt-get install xfce4

and following all the instructions.

Then to remove LXDE I carried out:

sudo apt-get --purge remove lxde
sudo apt-get clean

My problem lies that whenever I run

 startx

it still opens and runs LXDE? I know that I should be running

startxfce4

but I want to know how to completely remove LXDE? and understand how startx works?

Edit: Also how do I modify the startx file so that I can choose (if both are installed) which desktop environment I want startx to run?

Ghanima
  • 15,958
  • 17
  • 65
  • 125
gray_fox
  • 131
  • 1
  • 1
  • 6

2 Answers2

7

Follow the step-by-step guide provided by yours truly :-)

First install XFCE4 (consider also installing the xfce4-goodies package for extra visual candy)

sudo apt-get install xfce4

Then list all installed LXDE-related apps

sudo dpkg --get-selections | grep "^lx"

...and remove them

sudo apt-get remove lxappearance lxde lxde-* lxinput lxmenu-data lxpanel lxpolkit lxrandr lxsession* lxsession lxshortcut lxtask lxterminal

Note that alongside lxterminal also pistore will be purged! So if you want the Pi Store, don't remove the lxterminal package

During removal the update-alternatives script will be executed and set xfce4 as the default x-session-manager in /usr/bin/x-session-manager.

Reboot the RPi, for the changes to take effect.

Last but not least you should run the autoremove and autoclean command to clean any unnecessary packages

sudo apt-get autoremove && sudo apt-get autoclean

And you're all set! Enjoy the much more user-friendly XFCE.

Gonik
  • 91
  • 1
  • 1
  • 4
5

I posted this question in the Linux Stack Exchange as well, and a user named Vasa1 suggested to check

apt-cache show lxde

which listed all the associated packages with lxde, and therefore since lxde is a meta package, I therefore had to delete and remove the other associated packages in order to run startx to boot xfce4.

gray_fox
  • 131
  • 1
  • 1
  • 6