An old joke is that Emacs is a text editor with an operating system included, given that its extensibility and customization often goes far beyond traditional text editors. Part of its well-earned reputation comes from being built in Lisp which allows it to be expanded to do almost anything. Despite this in-joke in the community, though, you will still need an actual operating system to run it, but not much more than that.
This project uses User-Mode Linux (UML) as a foundation to load almost nothing other than an Emacs editor. UML is a virtualization technology that allows running multiple Linux kernel instances as separate virtual machines, so once the Linux environment is started and Emacs is compiled, the virtual machine can essentially boot straight into an Emacs environment. Some tools are needed outside of the Linux kernel like mount which allows the virtual file system to access the files needed to build Emacs, but as far as lightweight or minimalist Linux distributions go this one definitely gets at least an honorable mention.
While UML is virtualization software rather than a full-fledged Linux distribution, we would expect a similarly minimalist build could easily be done with something more hardware-based like Linux From Scratch. Emacs has been around for so long and had such a wide reach that it’s difficult to imagine a world without it. Even in more modern technology like browsers, knowing a little bit about Emacs can be an extremely powerful tool.
17 thoughts on “Build Your Own Bootable Emacs Environment”
emacs is like BDSM, some like it, most rather avoid the pain.
Like machine language on opiates.
If all that’s on a system is Emacs or vim…. I’ll install nano.
Unless… it’s an old UNIX system, or something not connected to the Internet. What are ya gonna do then? Learning vi isn’t that hard.
“Of course, on the system I administrate, vi is symlinked to ed. Emacs has been replaced by a shell script which 1) Generates a syslog message at level LOG_EMERG; 2) reduces the user’s disk quota by 100G; and 3) RUNS ED!!!!!!
“Ed is the standard text editor.””
I’ll use Emacs vi is for people who like torturing themselves.
I’m a vi bigot. Once when I was using VMS heavily I found a VMS port of emacs. That emacs was able to run a vi emulator called “vile”.
Eventually I found a windows port of vi called Lemmy. I got the developer to add a mode to open and write files via ftp, so I edited VMS files that way. I guess it was an early implementation of an fs-ftp type feature.
It really depends on what you do. If all you do is edit a text file once a year, then I totally understand why you would want to use nano. But for me, VIM is what I use instead of visual studio, excel, powerpoint, indesign, my diary, my notepad, etc etc etc. VIM isn’t just something you use as a simple text editor, it’s a software suite inside a single executable. You can modify it to do almost anything you want. If you put me in front of nano I get really confused and annoyed. I’ll stick to “VI VI VI, the editor of the beast” – Richard Stallman
This reminds me of the old Lisp machines of the ’80s that ran Emacs natively.
User Mode Linux! Awesome! Sadly, the article doesn’t say how they built their UML kernel, but my impression was that UML was abandonware since ca 2007 (see the 2.6 kernel you can download from the UML website).
Has anyone built a modern (Kernel 5 or 6 series) Linux as UML? I’d guess their SKAS patches won’t apply anymore, so things are probably slow…
I believe the UML patchset would have been abandoned when it was mainlined into upstream. Since 2.6 it’s been a built-in feature of the kernel; still around, but no longer a separate project.
Mezzano by [froggey] is an entire operating system written in LISP, which I assume can/does run EMACS too?
I would say the question is, can Emacs run Doom or not?
The old joke is that emacs is a perfectly good operating system lacking only a decent text editor.
There are vi emulators that run in emacs.
“Master, does Emacs have Buddha-nature?”
“… I can’t see why not; it has everything else.”
Please be kind and respectful to help make the comments section excellent. (Comment Policy)