Delete built-in packages in Emacs
Asked Answered
E

3

7

Is it possible to remove built-in Emacs packages like "tetris"? They can't be marked to be deleted in package list as of 24.1. It would be nice to have a minimal installation of Emacs - even though barely useful - by deleting some or all built-in packages. Is it possible to do somehow, and will this ability added in future?

Emplacement answered 13/5, 2012 at 15:50 Comment(1)
Since emacs won't load all packages at start up, I wonder what is your purpose to do that?Spectatress
C
9

Emacs should start and be useable even if the whole lisp directory is empty (note that we rarely/never test it, so I don't guarantee that it'll work, but at least in principle it should and if it doesn't you should report it with M-x report-emacs-bug). So feel free to remove any and all packages in there you don't find useful, in order to create a trimmed-down version of Emacs.

Conker answered 14/5, 2012 at 3:19 Comment(0)
R
5

You could just remove the elc files of all of the packages you want.

For example, in the version of emacs located in the ubuntu repository the tetris package is located in:

/usr/share/emacs/23.3/lisp/play/tetris.elc

If you move or remove it, emacs will continue to work, but you won't be able to play tetris anymore.

Rubber answered 13/5, 2012 at 16:1 Comment(0)
N
1

You might want to inspect the package--builtins variable. That said - there is little sense in removing any packages installed via package.el since package.el extracts and loads automatically only a package's autoloads - therefore having many installed packages doesn't result in any significant overhead. I'm quite certain that removing built-in packages will never be a feature of package.el.

Norite answered 14/5, 2012 at 5:48 Comment(1)
Evaluating autoloads causes significant slowdown at load time if you're the kind of person who keeps their init under 0.5s.Caramelize

© 2022 - 2024 — McMap. All rights reserved.