If you want a good vanilla Emacs experience, go with Medicated Emacs.
— Sun Tzu
Medicated Emacs enhances Emacs without hiding it. Everything uses standard Emacs patterns and conventions. No frameworks, wrappers, or special systems to learn. If you know how to customize vanilla Emacs, you know how to customize this config.
What you get:
- Modern completion (Vertico + Orderless + Marginalia)
- LSP support via Eglot (built-in)
- Git integration (Magit + diff-hl)
- Quality-of-life improvements (better defaults, recent files, etc.)
- Common language modes pre-installed
What you don't get:
- Custom keybinding schemes
- Framework abstractions
- Configuration complexity
- Non-standard Emacs patterns
- Emacs 29.0 or later
- Internet connection (for first-time package installation)
- LSP servers (optional, but required for language-specific features)
Ensure you have an empty Emacs configuration directory, or none at all. Your Emacs config directory is typically one of:
~/.emacs.d/~/.config/emacs/
If these exist and contain files, back them up and delete them, or Emacs may load conflicting configurations.
Place medicated.el as init.el in one of these locations:
~/.emacs.d/init.el(traditional location, always checked first)~/.config/emacs/init.el(XDG-compliant location)
Note: Emacs prefers ~/.emacs.d/ if it exists. To use the XDG location, ensure ~/.emacs.d/ does not exist.
Launch Emacs. On first run:
- All packages will be automatically downloaded and installed
- A message will appear: "First-time setup complete. Please restart Emacs."
- Emacs will automatically close after 10 seconds
Restart Emacs. Your configuration is now ready to use.
- Delete ALL files (including hidden files) in your Emacs directory
- Try the installation process again
- If problems persist, file a bug report with:
- Your Emacs version (
M-x emacs-version) - Your operating system
- Exact error messages
- Your Emacs version (
Eglot is enabled by default in all programming modes. This is the most common source of errors because:
- Eglot expects LSP servers to be already installed on your system
- If a language server is missing, you could see error messages
- Different languages need different LSP servers:
- C/C++: clangd
- Rust: rust-analyzer
- Python: pyright or pylsp
- Go: gopls
- JavaScript/TypeScript: typescript-language-server
- Lua: lua-language-server
- etc.
Solutions:
- Install the appropriate LSP server for your language
- Remove
eglot-ensurefromprog-mode-hookincustom-set-variables - Add Eglot only to specific language modes:
(add-hook 'rust-mode-hook #'eglot-ensure)
- Disable Eglot entirely and use Emacs without LSP
If you're new to Emacs, start with the built-in tutorial:
M-x help-with-tutorial RET
(That's: Alt+x, type "help-with-tutorial", press Enter)
Learn Emacs as you would with vanilla Emacs. This config doesn't change fundamental concepts. Standard Emacs documentation and resources apply directly.
Don't like something? Change it as you would in vanilla Emacs:
- Theme:
M-x customize-themesor editcustom-enabled-themes - Font:
M-x customize-face defaultor set indefault-frame-alist - Keybindings: Use
global-set-keyorlocal-set-key - Any setting:
M-x customize-variableor editcustom-set-variables
This config does nothing special, it's just Emacs with better defaults.
- csv-mode: CSV file editing
- diff-hl: Git diff indicators in the fringe
- doom-modeline: Modern mode-line
- doom-themes: Collection of themes (Gruvbox used by default)
- go-mode: Go language support
- helpful: Better help buffers
- json-mode: JSON highlight support
- lua-mode: Lua language support
- magit: Git interface
- marginalia: Completion annotations
- markdown-mode: Markdown editing
- orderless: Fuzzy completion matching
- rainbow-delimiters: Colored parentheses by depth
- rust-mode: Rust language support
- typescript-mode: TypeScript language support
- vertico: Vertical completion UI
- which key: Displays possible key bindings
- yaml-mode: YAML file editing
- Recent files tracking (
recentf-mode) - Cursor position memory (
save-place-mode) - Command history persistence (
savehist-mode) - Window configuration undo (
winner-mode) - Keybinding hints (
which-key-mode) - Visual line numbers (
display-line-numbers) - Better scrolling behavior
- Backup files in
~/.emacs.d/backups/ - Auto-save files in
~/.emacs.d/auto-saves/
All behavior (both functional and errors) from this config represents the normal Emacs experience, or bugs in the included third-party packages. When troubleshooting issues, standard Emacs debugging approaches apply. There's no special configuration layer to navigate.
This configuration is licensed under the 0BSD license.
