4

I don't like gedit and always use geany or vim or something else. Removing it from my current Debian testing install also removes the cinnamon-desktop-environment meta package because it depends on gedit. This meta package:

depends on all programs needed to have a fully fledged desktop environment. Install this if you want a complete cinnamon desktop, including graphical apps that allow users to perform almost all everyday tasks.

After removing it, apt shows that 209 packages are no longer necessary (because nothing depends on them) including Pidgin, LibreOffice, Gnome System Monitor, etc. Next time I want to run autoremove for another uninstalled application, it would remove all of them.

I guess the solution is to manually apt-get install the packages I actually want to have (i.e. Pidgin, LibreOffice, System Monitor, etc.), but there are also a bunch of packages of which I have no idea what they do. Many of them are probably dependencies of the aforementioned, but I don't know. I'd have to check them all manually. Some look unrelated, like t1utils (apt-cache rdepends doesn't show anything I recognize).

Another "solution" is to apt-get install the whole list of packages that it would otherwise autoremove, but that's an ugly hack because it would no longer know which packages were installed because of dependencies and which were installed because I want them to be installed.

I could also modify cinnamon-desktop-environment (e.g. by creating my own .deb) in some way that it doesn't depend on gedit while maintaining the other dependencies. I'm not sure how exactly, but it doesn't sound too hard. The issue with this is that it probably does not update anymore when there are updates because I installed a custom version of it.

Thinking about creating my own package, I looked into cinnamon-desktop-environment's dependencies. Surprise: it depends on firefox, which is not even available in Debian. And it depends on iceweasel, which I already uninstalled with no trouble. I don't understand.

How do I go about removing gedit without messing up my desktop environment?

  • 1
    It depends on iceweasel | firefox | chromium | gnome-www-browser, so as long as one of them is installed, the dependency is not broken. – Stéphane Chazelas Aug 7 '15 at 15:13
  • @StéphaneChazelas That explains one thing, thanks! Still though, the main question remains: how to remove gedit? Looking at the dependencies again, there are no alternatives it accepts. – Luc Aug 7 '15 at 15:29
  • 1
    Why do you want to remove gedit? If you don't want to use it, don't use it. – Faheem Mitha Aug 8 '15 at 0:56
  • "I guess the solution is to manually apt-get install the packages I actually want to have (i.e. Pidgin, LibreOffice, System Monitor, etc.), but there are also a bunch of packages of which I have no idea what they do. Many of them are probably dependencies of the aforementioned, but I don't know. I'd have to check them all manually.".Yes, just manually install the packages you want, and don't manually install packages you don't know / don't care about. Why would you install packages you don't know? – Faheem Mitha Aug 8 '15 at 0:58
  • "If you don't want to use it, don't use it" I also don't want unnecessary bloat on my system. It's like on default Windows installs where you get a bunch of trial software, there too you could say the same. – Luc Aug 9 '15 at 15:24
1

Removing a program just because you don't use it shows a misguided sense of priorities. Disk space is cheap. Gedit takes less than 2MB of disk space. Even at SSD RAID-1 prices, that costs less than ½¢. At the minimum wage in my country, it takes less than 2s to earn that much. It'll take you far more than 2 seconds to do this. The gains from removing the package are negligible — only the network and disk bandwidth when the package is installed.

That being said, here's how you can do it.


The cinnamon-desktop-environment package depends on the applications that are officially part of the Cinnamon desktop environment. Gedit is one of them.

If you want to remove Gedit but keep the rest of Cinnamon, mark the dependencies of cinnamon-desktop-environment except gedit as manually installed, then remove cinnamon-desktop-environment. You take the responsibility of adding any component that might be added to Cinnamon in the future. You can use aptitude search to list the packages that Cinnamon depends on.

aptitude unmarkauto $(aptitude -F %p search '~i ~Rcinnamon-desktop-environment !^gedit$')
apt-get remove gedit

Alternatively, you could make a fake gedit package that exists solely to resolve the dependency but doesn't contain the gedit binary. You can use equivs to make such fake packages. Note that some Cinnamon configuration may still believe that Gedit is present and attempt to call the nonexistent binary.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.