From 8464364a736528623e55db55439e35284d296409 Mon Sep 17 00:00:00 2001 From: James Cherti <60946298+jamescherti@users.noreply.github.com> Date: Mon, 18 Aug 2025 10:56:43 -0400 Subject: [PATCH 01/30] Update README.md --- README.md | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/README.md b/README.md index 40be20b..3b7c757 100644 --- a/README.md +++ b/README.md @@ -1287,6 +1287,20 @@ NOTE: `flyspell-mode` can become slow when using Aspell, especially with large b To configure **flyspell**, add the following to `~/.emacs.d/post-init.el`: ``` emacs-lisp +;; The flyspell package is a built-in Emacs minor mode that provides +;; on-the-fly spell checking. It highlights misspelled words as you type, +;; offering interactive corrections. In text modes, it checks the entire buffer, +;; while in programming modes, it typically checks only comments and strings. It +;; integrates with external spell checkers like aspell, hunspell, or +;; ispell to provide suggestions and corrections. +;; +;; NOTE: flyspell-mode can become slow when using Aspell, especially with large +;; buffers or aggressive suggestion settings like --sug-mode=ultra. This +;; slowdown occurs because Flyspell checks words dynamically as you type or +;; navigate text, requiring frequent communication between Emacs and the +;; external Aspell process. Each check involves sending words to Aspell and +;; receiving results, which introduces overhead from process invocation and +;; inter-process communication. (use-package ispell :ensure nil :commands (ispell ispell-minor-mode) From f986bc5e624f54379cbd4f0ee3fac844395bdf29 Mon Sep 17 00:00:00 2001 From: James Cherti <60946298+jamescherti@users.noreply.github.com> Date: Mon, 18 Aug 2025 19:49:50 -0400 Subject: [PATCH 02/30] Update README.md --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index 3b7c757..4210f81 100644 --- a/README.md +++ b/README.md @@ -1996,6 +1996,7 @@ A drawback of using the early-init phase instead of init is that if a package fa - [Leading_Ad6415 commented on Reddit](https://www.reddit.com/r/emacs/comments/1feaf37/comment/lmw7ijd/) that after switching to *minimal-emacs.d*, their configuration execution time decreased from 3 seconds to just 1 second by simply replacing their `init.el` and `early-init.el` files with those from the project. - [Another user commented on Reddit](https://www.reddit.com/r/emacs/comments/1feaf37/comment/lrsfd64/), highlighting how a minimal-emacs.d significantly enhanced their Emacs performance. They reported substantial startup time reductions on both their main machine (from ~2.25 to ~0.95 seconds) and an older laptop (from ~2.95 to ~1.27 seconds) while also experiencing a generally snappier performance within Emacs. The user expressed gratitude for the project, calling it fantastic. - [Cyneox commented on Reddit](https://www.reddit.com/r/emacs/comments/1gh687a/comment/lwdv18t/), expressing gratitude for the resource and sharing their experience. They mentioned it was their fourth attempt to set up a vanilla configuration and highlighted that they had been using the repository as a foundation for their customizations over the past few days. They appreciated the absence of unexplained behavior and the clear instructions on where to place files. The user reported successful testing on both Linux and macOS, noting that everything functioned smoothly, including in the terminal. +- [Sebagabones](https://github.com/jamescherti/minimal-emacs.d/issues/77): "...let me say that I am loving minimal-emacs.d, it has been brilliant so far! :)" - [Mlepnos1984](https://www.reddit.com/r/emacs/comments/1lz181i/comment/n2yjj17/): "I give you an A+ on documentation, the readme is great!" - [rrajath](https://www.reddit.com/r/emacs/comments/1ihn2tv/comment/mb0ja8k/) has been using the minimal-emacs.d config for the past several months and loves it. His previous setup used to take around 4 seconds to load, but with minimal-emacs.d, it now loads in just 1 second. - [LionyxML](https://www.reddit.com/r/emacs/comments/1ihn2tv/comment/mb35t9y/) considers that *minimal-emacs.d* contains one of the best README files he has ever read. The author of *minimal-emacs.d* found his comment encouraging. Reading this README.md is highly recommended for anyone looking to start customizing their *minimal-emacs.d* configuration. From 87252c8e3385669c486e05e2c38f19f2f8011dc3 Mon Sep 17 00:00:00 2001 From: James Cherti <60946298+jamescherti@users.noreply.github.com> Date: Tue, 19 Aug 2025 13:29:44 -0400 Subject: [PATCH 03/30] Add tags-table-mode to dabbrev-ignored-buffer-modes --- init.el | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/init.el b/init.el index 90d822a..937cf7b 100644 --- a/init.el +++ b/init.el @@ -528,7 +528,8 @@ (setq dabbrev-upcase-means-case-search t) (setq dabbrev-ignored-buffer-modes - '(archive-mode image-mode docview-mode tags-table-mode pdf-view-mode)) + '(archive-mode image-mode docview-mode tags-table-mode + pdf-view-mode tags-table-mode)) (setq dabbrev-ignored-buffer-regexps '(;; - Buffers starting with a space (internal or temporary buffers) From 2fd068149a3cc60d994502c7ba00aa47378ff536 Mon Sep 17 00:00:00 2001 From: James Cherti <60946298+jamescherti@users.noreply.github.com> Date: Thu, 21 Aug 2025 23:16:08 -0400 Subject: [PATCH 04/30] Update README.md --- README.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 4210f81..17eb8ca 100644 --- a/README.md +++ b/README.md @@ -112,7 +112,7 @@ In addition to *minimal-emacs.d*, startup speed is influenced by your computer's - [Why did the author develop minimal-emacs.d?](#why-did-the-author-develop-minimal-emacsd) - [How to keep minimal-emacs.d pre-\*.el and post-\*.el files in a separate directory?](#how-to-keep-minimal-emacsd-pre-el-and-post-el-files-in-a-separate-directory) - [How to make *minimal-emacs.d* install packages in the early-init phase instead of the init phase?](#how-to-make-minimal-emacsd-install-packages-in-the-early-init-phase-instead-of-the-init-phase) - - [Comments from users](#comments-from-users) + - [Testimonials from users](#testimonials-from-users) - [Minimal-emacs.d configurations from users](#minimal-emacsd-configurations-from-users) - [Features](#features) - [Author and license](#author-and-license) @@ -1989,10 +1989,10 @@ To install and load packages during the early-init phase, add the following to ` A drawback of using the early-init phase instead of init is that if a package fails (e.g, due to a network issue), no output will be displayed in the Emacs GUI. You will need to open a terminal to view Emacs's stdout for error messages. -### Comments from users +### Testimonials from users - [JamesBrickley (Shout out to this starter-kit: Minimal-Emacs )](https://www.reddit.com/r/emacs/comments/1epz7qn/shout_out_to_this_starterkit_minimalemacs/) appreciates that *minimal-emacs.d* provides an optimized *early-init.el* and *init.el* for fast startup times and sensible default settings. He highlights that the project includes all the essential configurations needed for a well-tuned Emacs setup, eliminating the need to sift through conflicting advice on topics like garbage collection optimization. While he has encountered similar settings before, he also discovered new optimizations he had not seen elsewhere. -- [Brandon Schneider (skarekrow)](https://github.com/skarekrow): "...the minimal-emacs project is incredible. I love how documented it is as a beginner to learn from. Thank you for all the effort you've put into that and the other packages you maintain. It's a huge boon to new users." +- [Brandon Schneider (skarekrow)](https://github.com/jamescherti/compile-angel.el/issues/5#issuecomment-3186187000): "...the minimal-emacs project is incredible. I love how documented it is as a beginner to learn from. Thank you for all the effort you've put into that and the other packages you maintain. It's a huge boon to new users." - [Leading_Ad6415 commented on Reddit](https://www.reddit.com/r/emacs/comments/1feaf37/comment/lmw7ijd/) that after switching to *minimal-emacs.d*, their configuration execution time decreased from 3 seconds to just 1 second by simply replacing their `init.el` and `early-init.el` files with those from the project. - [Another user commented on Reddit](https://www.reddit.com/r/emacs/comments/1feaf37/comment/lrsfd64/), highlighting how a minimal-emacs.d significantly enhanced their Emacs performance. They reported substantial startup time reductions on both their main machine (from ~2.25 to ~0.95 seconds) and an older laptop (from ~2.95 to ~1.27 seconds) while also experiencing a generally snappier performance within Emacs. The user expressed gratitude for the project, calling it fantastic. - [Cyneox commented on Reddit](https://www.reddit.com/r/emacs/comments/1gh687a/comment/lwdv18t/), expressing gratitude for the resource and sharing their experience. They mentioned it was their fourth attempt to set up a vanilla configuration and highlighted that they had been using the repository as a foundation for their customizations over the past few days. They appreciated the absence of unexplained behavior and the clear instructions on where to place files. The user reported successful testing on both Linux and macOS, noting that everything functioned smoothly, including in the terminal. From 80813db2d57d3243891189602a91b5ce25576bdb Mon Sep 17 00:00:00 2001 From: James Cherti <60946298+jamescherti@users.noreply.github.com> Date: Mon, 25 Aug 2025 15:13:53 -0400 Subject: [PATCH 05/30] Change scroll-conservatively to 10 --- init.el | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/init.el b/init.el index 937cf7b..8711f3f 100644 --- a/init.el +++ b/init.el @@ -272,9 +272,10 @@ ;; Keep screen position if scroll command moved it vertically out of the window. (setq scroll-preserve-screen-position t) -;; If `scroll-conservatively' is set above 100, the window is never -;; automatically recentered, which decreases the time spend recentering. -(setq scroll-conservatively 101) +;; Emacs recenters the window when the cursor moves past `scroll-conservatively' +;; lines beyond the window edge. A value over 101 disables recentering; the +;; default (0) is too eager. Here it is set to 10 for a balanced behavior. +(setq scroll-conservatively 10) ;; 1. Preventing automatic adjustments to `window-vscroll' for long lines. ;; 2. Resolving the issue of random half-screen jumps during scrolling. From 429d3a6697ba92428213553717109287ba4f9fb3 Mon Sep 17 00:00:00 2001 From: James Cherti <60946298+jamescherti@users.noreply.github.com> Date: Tue, 26 Aug 2025 17:18:00 -0400 Subject: [PATCH 06/30] Update README.md --- README.md | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 17eb8ca..0f81d89 100644 --- a/README.md +++ b/README.md @@ -252,8 +252,9 @@ Native compilation enhances Emacs performance by converting Elisp code into nati ;; files. If you choose to remove this push to `compile-angel-excluded-files' ;; and compile your pre/post-init files, ensure you understand the ;; implications and thoroughly test your code. For example, if you're using - ;; `use-package', you'll need to explicitly add `(require 'use-package)` at - ;; the top of your init file. + ;; the `use-package' macro, you'll need to explicitly add: + ;; (eval-when-compile (require 'use-package)) + ;; at the top of your init file. (push "/init.el" compile-angel-excluded-files) (push "/early-init.el" compile-angel-excluded-files) (push "/pre-init.el" compile-angel-excluded-files) From 2d69fbf55441010404cae77cdf52aed278f4ba26 Mon Sep 17 00:00:00 2001 From: James Cherti <60946298+jamescherti@users.noreply.github.com> Date: Tue, 26 Aug 2025 22:39:40 -0400 Subject: [PATCH 07/30] Enhance minimal-emacs-load-user-init Enhance minimal-emacs-load-user-init to display a message when Emacs starts with --debug-init mode. --- early-init.el | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/early-init.el b/early-init.el index d959cd6..197c50b 100644 --- a/early-init.el +++ b/early-init.el @@ -138,11 +138,12 @@ pre-early-init.el, and post-early-init.el.") (let ((init-file (expand-file-name filename minimal-emacs-user-directory))) (if (not minimal-emacs-load-compiled-init-files) - (load init-file :no-error :no-message :nosuffix) + (load init-file :no-error (not (bound-and-true-p init-file-debug)) + :nosuffix) ;; Remove the file suffix (.el, .el.gz, etc.) to let the `load' function ;; select between .el and .elc files. (setq init-file (minimal-emacs--remove-el-file-suffix init-file)) - (load init-file :no-error :no-message)))) + (load init-file :no-error (not (bound-and-true-p init-file-debug)))))) (minimal-emacs-load-user-init "pre-early-init.el") From 19427b19cc4f0c29e6d55fd431702517006e034b Mon Sep 17 00:00:00 2001 From: James Cherti <60946298+jamescherti@users.noreply.github.com> Date: Wed, 27 Aug 2025 14:06:53 -0400 Subject: [PATCH 08/30] Update README.md --- README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.md b/README.md index 0f81d89..b26b995 100644 --- a/README.md +++ b/README.md @@ -9,6 +9,8 @@ The **minimal-emacs.d** project is a lightweight and optimized Emacs base (`init Building the *minimal-emacs.d* `init.el` and `early-init.el` was the result of **extensive research and testing** to fine-tune the best parameters and optimizations for an Emacs configuration. *(More information about the *minimal-emacs.d* features can be found here: [Features](#features).)* +If this enhances your workflow, please show your support by **⭐ starring minimal-emacs.d GitHub** to help more users discover its benefits. +
diff --git a/early-init.el b/early-init.el
index c120546..86a9960 100644
--- a/early-init.el
+++ b/early-init.el
@@ -24,10 +24,14 @@
;;; Internal variables
-(defvar minimal-emacs--backup-gc-cons-threshold gc-cons-threshold
- "Backup of the original value of `gc-cons-threshold' before startup.")
+;; Backup of `gc-cons-threshold' and `gc-cons-percentage' before startup.
+(defvar minimal-emacs--backup-gc-cons-threshold gc-cons-threshold)
+(defvar minimal-emacs--backup-gc-cons-percentage gc-cons-percentage)
-(setq gc-cons-threshold most-positive-fixnum)
+;; Temporarily raise the garbage collection threshold to its maximum value.
+;; It will be restored later to controlled values.
+(setq gc-cons-threshold (- most-positive-fixnum 1))
+(setq gc-cons-percentage 1.0)
;;; Variables
@@ -55,6 +59,10 @@ stored in `minimal-emacs-gc-cons-threshold'.")
"Value to which `gc-cons-threshold' is set after Emacs startup.
Ignored if `minimal-emacs-optimize-startup-gc' is nil.")
+(defvar minimal-emacs-gc-cons-percentage gc-cons-percentage
+ "Value to which `gc-cons-percentage' is set after Emacs startup.
+Ignored if `minimal-emacs-optimize-startup-gc' is nil.")
+
(defvar minimal-emacs-gc-cons-threshold-restore-delay nil
"Number of seconds to wait before restoring `gc-cons-threshold'.")
@@ -157,23 +165,26 @@ pre-early-init.el, and post-early-init.el.")
(setq garbage-collection-messages minimal-emacs-debug)
-(defun minimal-emacs--restore-gc-cons-threshold ()
- "Restore `gc-cons-threshold' to `minimal-emacs-gc-cons-threshold'."
+(defun minimal-emacs--restore-gc-values ()
+ "Restore garbage collection values to minimal-emacs.d values."
+ (setq gc-cons-threshold minimal-emacs-gc-cons-threshold)
+ (setq gc-cons-percentage minimal-emacs-gc-cons-percentage))
+
+(defun minimal-emacs--restore-gc ()
+ "Restore garbage collection settings."
(if (bound-and-true-p minimal-emacs-gc-cons-threshold-restore-delay)
;; Defer garbage collection during initialization to avoid 2 collections.
- (run-at-time
- minimal-emacs-gc-cons-threshold-restore-delay nil
- (lambda () (setq gc-cons-threshold minimal-emacs-gc-cons-threshold)))
- (setq gc-cons-threshold minimal-emacs-gc-cons-threshold)))
+ (run-at-time minimal-emacs-gc-cons-threshold-restore-delay nil
+ #'minimal-emacs--restore-gc-values)
+ (minimal-emacs--restore-gc-values)))
(if minimal-emacs-optimize-startup-gc
;; `gc-cons-threshold' is managed by minimal-emacs.d
- (add-hook 'emacs-startup-hook #'minimal-emacs--restore-gc-cons-threshold 105)
+ (add-hook 'emacs-startup-hook #'minimal-emacs--restore-gc 105)
;; gc-cons-threshold is not managed by minimal-emacs.d.
- ;; If it is equal to `most-positive-fixnum', this indicates that the user has
- ;; not overridden the value in their `pre-early-init.el' configuration.
- (when (= gc-cons-threshold most-positive-fixnum)
- (setq gc-cons-threshold minimal-emacs--backup-gc-cons-threshold)))
+ (when (= gc-cons-threshold (- most-positive-fixnum 1))
+ (setq gc-cons-threshold minimal-emacs--backup-gc-cons-threshold)
+ (setq gc-cons-percentage minimal-emacs--backup-gc-cons-percentage)))
;;; Native compilation and Byte compilation
From 6ad66c87ebcb86af631b80a32fb0681b38daf752 Mon Sep 17 00:00:00 2001
From: James Cherti <60946298+jamescherti@users.noreply.github.com>
Date: Wed, 27 Aug 2025 23:48:55 -0400
Subject: [PATCH 11/30] Fix minimal-emacs-gc-cons-threshold-restore-delay timer
---
early-init.el | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/early-init.el b/early-init.el
index 86a9960..b2297d2 100644
--- a/early-init.el
+++ b/early-init.el
@@ -174,8 +174,8 @@ pre-early-init.el, and post-early-init.el.")
"Restore garbage collection settings."
(if (bound-and-true-p minimal-emacs-gc-cons-threshold-restore-delay)
;; Defer garbage collection during initialization to avoid 2 collections.
- (run-at-time minimal-emacs-gc-cons-threshold-restore-delay nil
- #'minimal-emacs--restore-gc-values)
+ (run-with-timer minimal-emacs-gc-cons-threshold-restore-delay nil
+ #'minimal-emacs--restore-gc-values)
(minimal-emacs--restore-gc-values)))
(if minimal-emacs-optimize-startup-gc
From 87bca021cc7ad4907faacc5fadc41866766a7be0 Mon Sep 17 00:00:00 2001
From: James Cherti <60946298+jamescherti@users.noreply.github.com>
Date: Thu, 28 Aug 2025 08:16:35 -0400
Subject: [PATCH 12/30] Update README.md
---
README.md | 1 +
1 file changed, 1 insertion(+)
diff --git a/README.md b/README.md
index a4b4ea2..f186c2e 100644
--- a/README.md
+++ b/README.md
@@ -243,6 +243,7 @@ Native compilation enhances Emacs performance by converting Elisp code into nati
;; Ensure adding the following compile-angel code at the very beginning
;; of your `~/.emacs.d/post-init.el` file, before all other packages.
(use-package compile-angel
+ :demand t
:ensure t
:custom
;; Set `compile-angel-verbose` to nil to suppress output from compile-angel.
From 932a7d5d413a6a504952ccb52b5fee4324b8f909 Mon Sep 17 00:00:00 2001
From: James Cherti <60946298+jamescherti@users.noreply.github.com>
Date: Thu, 28 Aug 2025 09:14:54 -0400
Subject: [PATCH 13/30] Update GC config
---
early-init.el | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/early-init.el b/early-init.el
index b2297d2..399b1f0 100644
--- a/early-init.el
+++ b/early-init.el
@@ -30,7 +30,7 @@
;; Temporarily raise the garbage collection threshold to its maximum value.
;; It will be restored later to controlled values.
-(setq gc-cons-threshold (- most-positive-fixnum 1))
+(setq gc-cons-threshold most-positive-fixnum)
(setq gc-cons-percentage 1.0)
;;; Variables
@@ -182,7 +182,7 @@ pre-early-init.el, and post-early-init.el.")
;; `gc-cons-threshold' is managed by minimal-emacs.d
(add-hook 'emacs-startup-hook #'minimal-emacs--restore-gc 105)
;; gc-cons-threshold is not managed by minimal-emacs.d.
- (when (= gc-cons-threshold (- most-positive-fixnum 1))
+ (when (= gc-cons-threshold most-positive-fixnum)
(setq gc-cons-threshold minimal-emacs--backup-gc-cons-threshold)
(setq gc-cons-percentage minimal-emacs--backup-gc-cons-percentage)))
From 1c72902cc30b7ffe0de658a289f658b0c0433561 Mon Sep 17 00:00:00 2001
From: James Cherti <60946298+jamescherti@users.noreply.github.com>
Date: Fri, 29 Aug 2025 16:48:03 -0400
Subject: [PATCH 14/30] Change scroll-conservatively to 20 to fix jumping
issues in org-mode buffers
---
init.el | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/init.el b/init.el
index 8711f3f..9ad7a43 100644
--- a/init.el
+++ b/init.el
@@ -274,8 +274,8 @@
;; Emacs recenters the window when the cursor moves past `scroll-conservatively'
;; lines beyond the window edge. A value over 101 disables recentering; the
-;; default (0) is too eager. Here it is set to 10 for a balanced behavior.
-(setq scroll-conservatively 10)
+;; default (0) is too eager. Here it is set to 20 for a balanced behavior.
+(setq scroll-conservatively 20)
;; 1. Preventing automatic adjustments to `window-vscroll' for long lines.
;; 2. Resolving the issue of random half-screen jumps during scrolling.
From fa0229219663ab848988188aec8d48c696ded00c Mon Sep 17 00:00:00 2001
From: James Cherti <60946298+jamescherti@users.noreply.github.com>
Date: Mon, 1 Sep 2025 16:12:37 -0400
Subject: [PATCH 15/30] Update README.md
---
README.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/README.md b/README.md
index f186c2e..1a598eb 100644
--- a/README.md
+++ b/README.md
@@ -1565,7 +1565,7 @@ To configure the *persist-text-scale* package, add the following to your `~/.ema
### Loading the custom.el file
-**NOTE:** The author advises against loading `custom.el`. To disable it, set `custom-file` to the null device using `(setq custom-file null-device)`. Users are instead encouraged to define their configuration programmatically in files such as `post-init.el`. Maintaining configuration programmatically offers several advantages: it ensures reproducibility and facilitates version control. This makes it easier to understand, audit, and evolve the configuration over time.
+**NOTE:** The author advises against loading `custom.el`. Users are instead encouraged to define their configuration programmatically in files such as `post-init.el`. Maintaining configuration programmatically offers several advantages: it ensures reproducibility and facilitates version control. This makes it easier to understand, audit, and evolve the configuration over time.
In Emacs, customization variables modified via the UI (e.g., `M-x customize`) are typically stored in a separate file, commonly named `custom.el`. To ensure these settings are loaded during Emacs initialization, it is necessary to explicitly load this file if it exists. To accomplish this, add the following form to your `~/.emacs.d/post-init.el`:
From f03e7da977ec791d342b82c2d122689af32b4062 Mon Sep 17 00:00:00 2001
From: James Cherti <60946298+jamescherti@users.noreply.github.com>
Date: Wed, 3 Sep 2025 10:45:23 -0400
Subject: [PATCH 16/30] Add MELPA stable and update the README.md file
---
README.md | 44 ++++++++++++++++++++++++++++++++++++++------
early-init.el | 10 ++++++----
2 files changed, 44 insertions(+), 10 deletions(-)
diff --git a/README.md b/README.md
index 1a598eb..5fac1cc 100644
--- a/README.md
+++ b/README.md
@@ -103,6 +103,7 @@ In addition to *minimal-emacs.d*, startup speed is influenced by your computer's
- [Frequently asked questions](#frequently-asked-questions)
- [Customizing Scroll Recentering](#customizing-scroll-recentering)
- [How to display Emacs startup duration?](#how-to-display-emacs-startup-duration)
+ - [How to get the latest version of all packages?](#how-to-get-the-latest-version-of-all-packages)
- [How to use MELPA stable?](#how-to-use-melpa-stable)
- [How to load a local lisp file for machine-specific configurations?](#how-to-load-a-local-lisp-file-for-machine-specific-configurations)
- [How to load Emacs customizations?](#how-to-load-emacs-customizations)
@@ -1851,6 +1852,40 @@ Add the following to your `~/.emacs.d/pre-early-init.el` file:
(Alternatively, you may use the built-in `M-x emacs-init-time` command to obtain the startup duration. However, `emacs-init-time` does not account for the portion of the startup process that occurs after `after-init-time`.)
+### How to get the latest version of all packages?
+
+By default, `minimal-emacs.d` is configured to prioritize packages from GNU and NonGNU repositories over MELPA, ensuring greater stability.
+
+If, like the author of `minimal-emacs.d`, you prefer to obtain the latest packages from MELPA to access new features and improvements, you can adjust the priority so that Emacs `use-package` retrieves the newest versions from MELPA before consulting the stable GNU and nongnu repositories. While MELPA packages are generally regarded as less stable, actual breakages are uncommon; over the past year, only a single package (`package-lint`) in the author’s configuration experienced a brief disruption, which was quickly resolved.
+
+Benefit:
+
+* Ensures access to the **most recent package versions**, enabling early adoption of new features, performance improvements, and upstream bug fixes.
+* Prioritizing MELPA provides a **broader selection of cutting-edge packages**, including experimental or niche tools that may not yet exist in stable archives.
+
+Drawback:
+
+* Exposure to **potential instability**, as MELPA packages are often built from the latest commits without extensive regression testing.
+* May require **periodic maintenance**, such as resolving dependency conflicts or adapting to API changes in packages that evolve rapidly.
+
+To ensure that Emacs always installs or updates to the newest versions of all packages, add the following configuration to `~/.emacs.d/post-early-init.el`:
+
+```elisp
+(setq package-archive-priorities '(("melpa" . 90)
+ ("gnu" . 70)
+ ("nongnu" . 60)
+ ("melpa-stable" . 50)))
+```
+
+This setup prioritizes **MELPA** over the stable GNU and NonGNU repositories. When multiple archives provide the same package, Emacs will choose the version from the archive with the highest priority. As a result, you will consistently receive the latest available versions from MELPA while still having access to stable GNU and NonGNU packages when MELPA does not provide them.
+
+In the event of a package breakage, you can direct Emacs to install a package from a specific repository. For instance, to ensure that `evil` and `evil-collection` are installed from melpa-stable, add the following configuration to `~/.emacs.d/post-early-init.el`:
+```elisp
+(setq package-pinned-packages
+ '((evil . "melpa-stable")
+ (evil-numbers . "melpa-stable")))
+```
+
### How to use MELPA stable?
**Note: The minimal-emacs.d author does not recommend using MELPA Stable. Use MELPA instead, which is enabled by default in the minimal-emacs.d configuration.**
@@ -1864,16 +1899,13 @@ Here are the key differences between **MELPA** (the default repository used in m
If you prefer MELPA Stable over MELPA, you can add MELPA Stable and prioritize it. To ensure packages are fetched from MELPA Stable first, add the following configuration to `~/.emacs.d/post-early-init.el`:
```elisp
-;; Add melpa-stable to `package-archives'
-(push '("melpa-stable" . "https://stable.melpa.org/packages/") package-archives)
-
;; This change increases MELPA Stable priority to 70, above MELPA,
;; ensuring that MELPA is preferred for package installations
;; over MELPA Stable.
-(setq package-archive-priorities '(("gnu" . 99)
- ("nongnu" . 80)
+(setq package-archive-priorities '(("gnu" . 90)
+ ("nongnu" . 80)
("melpa-stable" . 70)
- ("melpa" . 0)))
+ ("melpa" . 60)))
```
### How to load a local lisp file for machine-specific configurations?
diff --git a/early-init.el b/early-init.el
index 399b1f0..a0ef795 100644
--- a/early-init.el
+++ b/early-init.el
@@ -478,12 +478,14 @@ this stage of initialization."
(setq package-enable-at-startup nil) ; Let the init.el file handle this
(setq use-package-always-ensure t)
(setq use-package-enable-imenu-support t)
-(setq package-archives '(("melpa" . "https://melpa.org/packages/")
- ("gnu" . "https://elpa.gnu.org/packages/")
- ("nongnu" . "https://elpa.nongnu.org/nongnu/")))
+(setq package-archives '(("melpa" . "https://melpa.org/packages/")
+ ("gnu" . "https://elpa.gnu.org/packages/")
+ ("nongnu" . "https://elpa.nongnu.org/nongnu/")
+ ("melpa-stable" . "https://stable.melpa.org/packages/")))
(setq package-archive-priorities '(("gnu" . 99)
("nongnu" . 80)
- ("melpa" . 70)))
+ ("melpa" . 70)
+ ("melpa-stable" . 50)))
;;; Load post-early-init.el
(minimal-emacs-load-user-init "post-early-init.el")
From c0a8e6bf6ac5ae3d1fdeb5d76e268b3202d10843 Mon Sep 17 00:00:00 2001
From: James Cherti <60946298+jamescherti@users.noreply.github.com>
Date: Wed, 3 Sep 2025 11:12:14 -0400
Subject: [PATCH 17/30] Update README.md
---
README.md | 9 +++++++--
1 file changed, 7 insertions(+), 2 deletions(-)
diff --git a/README.md b/README.md
index 5fac1cc..d343cbe 100644
--- a/README.md
+++ b/README.md
@@ -1854,9 +1854,9 @@ Add the following to your `~/.emacs.d/pre-early-init.el` file:
### How to get the latest version of all packages?
-By default, `minimal-emacs.d` is configured to prioritize packages from GNU and NonGNU repositories over MELPA, ensuring greater stability.
+By default, minimal-emacs.d is configured to prioritize packages from GNU and NonGNU repositories over MELPA, ensuring greater stability.
-If, like the author of `minimal-emacs.d`, you prefer to obtain the latest packages from MELPA to access new features and improvements, you can adjust the priority so that Emacs `use-package` retrieves the newest versions from MELPA before consulting the stable GNU and nongnu repositories. While MELPA packages are generally regarded as less stable, actual breakages are uncommon; over the past year, only a single package (`package-lint`) in the author’s configuration experienced a brief disruption, which was quickly resolved.
+If, like the author of *minimal-emacs.d*, you prefer to obtain the latest packages from MELPA to access new features and improvements, you can adjust the priority so that Emacs `use-package` retrieves the newest versions from MELPA before consulting the stable GNU and nongnu repositories. While MELPA packages are generally regarded as less stable, actual breakages are uncommon; over the past year, only a single package (`package-lint`) out of 146 packages in the author’s configuration experienced a brief disruption, which was quickly resolved.
Benefit:
@@ -1871,6 +1871,11 @@ Drawback:
To ensure that Emacs always installs or updates to the newest versions of all packages, add the following configuration to `~/.emacs.d/post-early-init.el`:
```elisp
+;; Obtain the latest packages from MELPA to access new features and
+;; improvements. While MELPA packages are generally regarded as less stable,
+;; actual breakages are uncommon; over the past year, only a single package
+;; (package-lint) out of 146 packages in the minimal-emacs.d author’s
+;; configuration experienced a brief disruption, which was quickly resolved.
(setq package-archive-priorities '(("melpa" . 90)
("gnu" . 70)
("nongnu" . 60)
From 2b27ee6b0e7ed1c49c19af27a618b1d87ce5f1b0 Mon Sep 17 00:00:00 2001
From: James Cherti <60946298+jamescherti@users.noreply.github.com>
Date: Wed, 3 Sep 2025 11:16:16 -0400
Subject: [PATCH 18/30] Update README.md
---
README.md | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/README.md b/README.md
index d343cbe..c8b6b59 100644
--- a/README.md
+++ b/README.md
@@ -1856,7 +1856,7 @@ Add the following to your `~/.emacs.d/pre-early-init.el` file:
By default, minimal-emacs.d is configured to prioritize packages from GNU and NonGNU repositories over MELPA, ensuring greater stability.
-If, like the author of *minimal-emacs.d*, you prefer to obtain the latest packages from MELPA to access new features and improvements, you can adjust the priority so that Emacs `use-package` retrieves the newest versions from MELPA before consulting the stable GNU and nongnu repositories. While MELPA packages are generally regarded as less stable, actual breakages are uncommon; over the past year, only a single package (`package-lint`) out of 146 packages in the author’s configuration experienced a brief disruption, which was quickly resolved.
+If, like the author of *minimal-emacs.d*, you prefer to obtain the latest packages from MELPA to access new features and improvements, you can adjust the priority so that Emacs `use-package` retrieves the newest versions from MELPA before consulting the stable GNU and NonGNU repositories. While MELPA packages are generally regarded as less stable, actual breakages are uncommon; over the past year, only a single package (package-lint) out of 146 packages in the author’s configuration experienced a brief disruption, which was quickly resolved.
Benefit:
@@ -1866,7 +1866,7 @@ Benefit:
Drawback:
* Exposure to **potential instability**, as MELPA packages are often built from the latest commits without extensive regression testing.
-* May require **periodic maintenance**, such as resolving dependency conflicts or adapting to API changes in packages that evolve rapidly.
+* May require **periodic maintenance**, such as resolving dependency conflicts or adapting to API changes in packages that evolve rapidly. (actual breakages are uncommon.)
To ensure that Emacs always installs or updates to the newest versions of all packages, add the following configuration to `~/.emacs.d/post-early-init.el`:
From 15a27c1f40a472395f03b27bba9f2ead351a938a Mon Sep 17 00:00:00 2001
From: James Cherti <60946298+jamescherti@users.noreply.github.com>
Date: Wed, 3 Sep 2025 11:20:24 -0400
Subject: [PATCH 19/30] Update README.md
---
README.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/README.md b/README.md
index c8b6b59..453abc1 100644
--- a/README.md
+++ b/README.md
@@ -1884,7 +1884,7 @@ To ensure that Emacs always installs or updates to the newest versions of all pa
This setup prioritizes **MELPA** over the stable GNU and NonGNU repositories. When multiple archives provide the same package, Emacs will choose the version from the archive with the highest priority. As a result, you will consistently receive the latest available versions from MELPA while still having access to stable GNU and NonGNU packages when MELPA does not provide them.
-In the event of a package breakage, you can direct Emacs to install a package from a specific repository. For instance, to ensure that `evil` and `evil-collection` are installed from melpa-stable, add the following configuration to `~/.emacs.d/post-early-init.el`:
+In the event of a package breakage, you can direct Emacs to install a package from a specific repository. For instance, to ensure that *evil* and *evil-collection* are installed from *melpa-stable*, add the following configuration to `~/.emacs.d/post-early-init.el`:
```elisp
(setq package-pinned-packages
'((evil . "melpa-stable")
From 44bfe663930960b143505f4930ce6d0a520f5387 Mon Sep 17 00:00:00 2001
From: James Cherti <60946298+jamescherti@users.noreply.github.com>
Date: Wed, 3 Sep 2025 15:31:28 -0400
Subject: [PATCH 20/30] Remove settings that are already t by default
---
early-init.el | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/early-init.el b/early-init.el
index a0ef795..f113cbb 100644
--- a/early-init.el
+++ b/early-init.el
@@ -193,9 +193,7 @@ pre-early-init.el, and post-early-init.el.")
(native-comp-available-p))
(when minimal-emacs-setup-native-compilation
;; Activate `native-compile'
- (setq native-comp-deferred-compilation t
- native-comp-jit-compilation t
- package-native-compile t))
+ (setq package-native-compile t))
;; Deactivate the `native-compile' feature if it is not available
(setq features (delq 'native-compile features)))
From af942662c145e77bb8d783fd9f43f33ee537e519 Mon Sep 17 00:00:00 2001
From: James Cherti <60946298+jamescherti@users.noreply.github.com>
Date: Thu, 4 Sep 2025 11:02:05 -0400
Subject: [PATCH 21/30] Update README.md
---
README.md | 89 +++++++++++++++++++++++++++++++++++++++++++++++++++----
1 file changed, 83 insertions(+), 6 deletions(-)
diff --git a/README.md b/README.md
index 453abc1..f5e9536 100644
--- a/README.md
+++ b/README.md
@@ -103,7 +103,7 @@ In addition to *minimal-emacs.d*, startup speed is influenced by your computer's
- [Frequently asked questions](#frequently-asked-questions)
- [Customizing Scroll Recentering](#customizing-scroll-recentering)
- [How to display Emacs startup duration?](#how-to-display-emacs-startup-duration)
- - [How to get the latest version of all packages?](#how-to-get-the-latest-version-of-all-packages)
+ - [How to get the latest version of all packages? (unstable)](#how-to-get-the-latest-version-of-all-packages-unstable)
- [How to use MELPA stable?](#how-to-use-melpa-stable)
- [How to load a local lisp file for machine-specific configurations?](#how-to-load-a-local-lisp-file-for-machine-specific-configurations)
- [How to load Emacs customizations?](#how-to-load-emacs-customizations)
@@ -1852,11 +1852,11 @@ Add the following to your `~/.emacs.d/pre-early-init.el` file:
(Alternatively, you may use the built-in `M-x emacs-init-time` command to obtain the startup duration. However, `emacs-init-time` does not account for the portion of the startup process that occurs after `after-init-time`.)
-### How to get the latest version of all packages?
+### How to get the latest version of all packages? (unstable)
-By default, minimal-emacs.d is configured to prioritize packages from GNU and NonGNU repositories over MELPA, ensuring greater stability.
+By default, *minimal-emacs.d* is configured to prioritize packages from [GNU ELPA](https://elpa.gnu.org/) and [NonGNU ELPA](https://elpa.nongnu.org/) repositories over [MELPA](https://melpa.org/), ensuring greater stability.
-If, like the author of *minimal-emacs.d*, you prefer to obtain the latest packages from MELPA to access new features and improvements, you can adjust the priority so that Emacs `use-package` retrieves the newest versions from MELPA before consulting the stable GNU and NonGNU repositories. While MELPA packages are generally regarded as less stable, actual breakages are uncommon; over the past year, only a single package (package-lint) out of 146 packages in the author’s configuration experienced a brief disruption, which was quickly resolved.
+If you prefer to obtain the latest packages from MELPA to access new features and improvements, you can adjust the priority so that Emacs `use-package` retrieves the newest versions from MELPA before consulting the stable GNU and NonGNU repositories. While MELPA packages are generally regarded as less stable, actual breakages are uncommon; over the past year, only a single package (package-lint) out of 146 packages in the author’s configuration experienced a brief disruption, which was quickly resolved.
Benefit:
@@ -1887,8 +1887,85 @@ This setup prioritizes **MELPA** over the stable GNU and NonGNU repositories. Wh
In the event of a package breakage, you can direct Emacs to install a package from a specific repository. For instance, to ensure that *evil* and *evil-collection* are installed from *melpa-stable*, add the following configuration to `~/.emacs.d/post-early-init.el`:
```elisp
(setq package-pinned-packages
- '((evil . "melpa-stable")
- (evil-numbers . "melpa-stable")))
+ '((evil . "melpa-stable")
+ (evil-collection . "melpa-stable")))
+```
+
+Here is a comprehensive `package-pinned-packages` configuration to guarantee that essential packages, such as **consult** or **corfu**, are retrieved from a stable repository, while all remaining packages are obtained from MELPA according to the `package-archive-priorities' priorities above:
+```elisp
+(setq package-pinned-packages
+ '((org-appear . "melpa-stable")
+ (groovy-mode . "melpa-stable")
+ (flymake-quickdef . "melpa-stable")
+ (annalist . "melpa-stable")
+ (markdown-toc . "melpa-stable")
+ (elisp-refs . "melpa-stable")
+ (dumb-jump . "melpa-stable")
+ (evil-collection . "melpa-stable")
+ (consult-dir . "melpa-stable")
+ (prescient . "melpa-stable")
+ (corfu-prescient . "melpa-stable")
+ (vertico-prescient . "melpa-stable")
+ (dtrt-indent . "melpa-stable")
+ (f . "melpa-stable")
+ (s . "melpa-stable")
+ (apheleia . "melpa-stable")
+ (package-lint-flymake . "melpa-stable")
+ (ansible-doc . "melpa-stable")
+ (basic-mode . "melpa-stable")
+ (tocus . "melpa-stable")
+ (highlight-defined . "melpa-stable")
+ (parent-mode . "melpa-stable")
+ (visual-fill-column . "melpa-stable")
+ (yasnippet-snippets . "melpa-stable")
+ (php-mode . "melpa-stable")
+ (rainbow-mode . "gnu")
+ (ztree . "gnu")
+ (easy-escape . "gnu")
+ (csv-mode . "gnu")
+ (aggressive-indent . "gnu")
+ (yasnippet . "gnu")
+ (org . "gnu")
+ (embark-consult . "gnu")
+ (embark . "gnu")
+ (compat . "gnu")
+ (corfu . "gnu")
+ (cape . "gnu")
+ (consult . "gnu")
+ (orderless . "gnu")
+ (vertico . "gnu")
+ (indent-bars . "gnu")
+ (transient . "gnu")
+ (dash . "gnu")
+ (modus-themes . "gnu")
+ (marginalia . "gnu")
+ (avy . "gnu")
+ (ace-window . "gnu")
+ (expand-region . "gnu")
+ (diff-hl . "gnu")
+ (diminish . "gnu")
+ (rainbow-delimiters . "nongnu")
+ (with-editor . "nongnu")
+ (ws-butler . "nongnu")
+ (exec-path-from-shell . "nongnu")
+ (evil-visualstar . "nongnu")
+ (yaml-mode . "nongnu")
+ (undo-fu . "nongnu")
+ (undo-fu-session . "nongnu")
+ (golden-ratio . "nongnu")
+ (paredit . "nongnu")
+ (lua-mode . "nongnu")
+ (wgrep . "nongnu")
+ (popup . "nongnu")
+ (eat . "nongnu")
+ (goto-chg . "nongnu")
+ (git-modes . "nongnu")
+ (package-lint . "nongnu")
+ (markdown-mode . "nongnu")
+ (edit-indirect . "nongnu")
+ (page-break-lines . "nongnu")
+ (magit . "nongnu")
+ (gptel . "nongnu")))
```
### How to use MELPA stable?
From bc3615e706153a7e09872194d858e95e41aa94ec Mon Sep 17 00:00:00 2001
From: James Cherti <60946298+jamescherti@users.noreply.github.com>
Date: Thu, 4 Sep 2025 11:07:42 -0400
Subject: [PATCH 22/30] Update README.md
---
README.md | 120 +++++++++++++++++++++++++++---------------------------
1 file changed, 61 insertions(+), 59 deletions(-)
diff --git a/README.md b/README.md
index f5e9536..bf613a0 100644
--- a/README.md
+++ b/README.md
@@ -1894,78 +1894,80 @@ In the event of a package breakage, you can direct Emacs to install a package fr
Here is a comprehensive `package-pinned-packages` configuration to guarantee that essential packages, such as **consult** or **corfu**, are retrieved from a stable repository, while all remaining packages are obtained from MELPA according to the `package-archive-priorities' priorities above:
```elisp
(setq package-pinned-packages
- '((org-appear . "melpa-stable")
- (groovy-mode . "melpa-stable")
- (flymake-quickdef . "melpa-stable")
- (annalist . "melpa-stable")
- (markdown-toc . "melpa-stable")
- (elisp-refs . "melpa-stable")
- (dumb-jump . "melpa-stable")
- (evil-collection . "melpa-stable")
- (consult-dir . "melpa-stable")
- (prescient . "melpa-stable")
- (corfu-prescient . "melpa-stable")
- (vertico-prescient . "melpa-stable")
- (dtrt-indent . "melpa-stable")
- (f . "melpa-stable")
- (s . "melpa-stable")
- (apheleia . "melpa-stable")
- (package-lint-flymake . "melpa-stable")
+ '((annalist . "melpa-stable")
(ansible-doc . "melpa-stable")
+ (apheleia . "melpa-stable")
(basic-mode . "melpa-stable")
- (tocus . "melpa-stable")
+ (consult-dir . "melpa-stable")
+ (corfu-prescient . "melpa-stable")
+ (dtrt-indent . "melpa-stable")
+ (dumb-jump . "melpa-stable")
+ (elisp-refs . "melpa-stable")
+ (evil-collection . "melpa-stable")
+ (f . "melpa-stable")
+ (flymake-quickdef . "melpa-stable")
+ (groovy-mode . "melpa-stable")
(highlight-defined . "melpa-stable")
+ (markdown-toc . "melpa-stable")
+ (org-appear . "melpa-stable")
+ (package-lint-flymake . "melpa-stable")
(parent-mode . "melpa-stable")
+ (php-mode . "melpa-stable")
+ (prescient . "melpa-stable")
+ (s . "melpa-stable")
+ (tocus . "melpa-stable")
+ (treesit-auto . "melpa-stable")
+ (vertico-prescient . "melpa-stable")
(visual-fill-column . "melpa-stable")
(yasnippet-snippets . "melpa-stable")
- (php-mode . "melpa-stable")
- (rainbow-mode . "gnu")
- (ztree . "gnu")
- (easy-escape . "gnu")
- (csv-mode . "gnu")
- (aggressive-indent . "gnu")
- (yasnippet . "gnu")
- (org . "gnu")
- (embark-consult . "gnu")
- (embark . "gnu")
- (compat . "gnu")
- (corfu . "gnu")
- (cape . "gnu")
- (consult . "gnu")
- (orderless . "gnu")
- (vertico . "gnu")
- (indent-bars . "gnu")
- (transient . "gnu")
- (dash . "gnu")
- (modus-themes . "gnu")
- (marginalia . "gnu")
- (avy . "gnu")
(ace-window . "gnu")
- (expand-region . "gnu")
+ (aggressive-indent . "gnu")
+ (avy . "gnu")
+ (cape . "gnu")
+ (compat . "gnu")
+ (consult . "gnu")
+ (corfu . "gnu")
+ (csv-mode . "gnu")
+ (dash . "gnu")
(diff-hl . "gnu")
(diminish . "gnu")
- (rainbow-delimiters . "nongnu")
- (with-editor . "nongnu")
- (ws-butler . "nongnu")
- (exec-path-from-shell . "nongnu")
+ (easy-escape . "gnu")
+ (embark . "gnu")
+ (embark-consult . "gnu")
+ (expand-region . "gnu")
+ (gcmh . "gnu")
+ (indent-bars . "gnu")
+ (marginalia . "gnu")
+ (modus-themes . "gnu")
+ (orderless . "gnu")
+ (org . "gnu")
+ (rainbow-mode . "gnu")
+ (transient . "gnu")
+ (vertico . "gnu")
+ (yasnippet . "gnu")
+ (ztree . "gnu")
+ (eat . "nongnu")
+ (edit-indirect . "nongnu")
(evil-visualstar . "nongnu")
- (yaml-mode . "nongnu")
+ (exec-path-from-shell . "nongnu")
+ (git-modes . "nongnu")
+ (golden-ratio . "nongnu")
+ (goto-chg . "nongnu")
+ (gptel . "nongnu")
+ (lua-mode . "nongnu")
+ (magit . "nongnu")
+ (markdown-mode . "nongnu")
+ (package-lint . "nongnu")
+ (page-break-lines . "nongnu")
+ (paredit . "nongnu")
+ (popup . "nongnu")
+ (rainbow-delimiters . "nongnu")
(undo-fu . "nongnu")
(undo-fu-session . "nongnu")
- (golden-ratio . "nongnu")
- (paredit . "nongnu")
- (lua-mode . "nongnu")
(wgrep . "nongnu")
- (popup . "nongnu")
- (eat . "nongnu")
- (goto-chg . "nongnu")
- (git-modes . "nongnu")
- (package-lint . "nongnu")
- (markdown-mode . "nongnu")
- (edit-indirect . "nongnu")
- (page-break-lines . "nongnu")
- (magit . "nongnu")
- (gptel . "nongnu")))
+ (with-editor . "nongnu")
+ (ws-butler . "nongnu")
+ (yaml-mode . "nongnu")))
```
### How to use MELPA stable?
From 862b6dc253615da2681257aa410d91c2e0359519 Mon Sep 17 00:00:00 2001
From: James Cherti <60946298+jamescherti@users.noreply.github.com>
Date: Fri, 5 Sep 2025 08:34:45 -0400
Subject: [PATCH 23/30] Update README.md
---
README.md | 138 +++++++++++++++++++++++++++---------------------------
1 file changed, 69 insertions(+), 69 deletions(-)
diff --git a/README.md b/README.md
index bf613a0..28422e5 100644
--- a/README.md
+++ b/README.md
@@ -9,7 +9,7 @@ The **minimal-emacs.d** project is a lightweight and optimized Emacs base (`init
Building the *minimal-emacs.d* `init.el` and `early-init.el` was the result of **extensive research and testing** to fine-tune the best parameters and optimizations for an Emacs configuration. *(More information about the *minimal-emacs.d* features can be found here: [Features](#features).)*
-If this enhances your workflow, please show your support by **⭐ starring minimal-emacs.d GitHub** to help more Emacs users discover its benefits.
+If this enhances your workflow, please show your support by **⭐ starring minimal-emacs.d on GitHub** to help more Emacs users discover its benefits.
@@ -52,74 +52,74 @@ In addition to *minimal-emacs.d*, startup speed is influenced by your computer's
## Table of Contents
- [*minimal-emacs.d* - A Customizable Emacs `init.el` and `early-init.el` that Provides Better Defaults and Faster Startup](#minimal-emacsd---a-customizable-emacs-initel-and-early-initel-that-provides-better-defaults-and-faster-startup)
- - [Introduction](#introduction)
- - [Looking for the ideal starter kit to customize Emacs? You have found it.](#looking-for-the-ideal-starter-kit-to-customize-emacs-you-have-found-it)
- - [Startup](#startup)
- - [Install minimal-emacs.d](#install-minimal-emacsd)
- - [Install minimal-emacs.d into `~/.emacs.d`](#install-minimal-emacsd-into-emacsd)
- - [Alternative: Install minimal-emacs.d into `~/.minimal-emacs.d`](#alternative-install-minimal-emacsd-into-minimal-emacsd)
- - [Update minimal-emacs.d](#update-minimal-emacsd)
- - [Customizations: Never modify init.el and early-init.el. Modify these instead...](#customizations-never-modify-initel-and-early-initel-modify-these-instead)
- - [Debug on error](#debug-on-error)
- - [Customizations: UI (pre-early-init.el)](#customizations-ui-pre-early-initel)
- - [How to enable the menu-bar, the tool-bar, dialogs, the contextual menu, and tooltips?](#how-to-enable-the-menu-bar-the-tool-bar-dialogs-the-contextual-menu-and-tooltips)
- - [Reducing clutter in `~/.emacs.d` by redirecting files to `~/.emacs.d/var/`](#reducing-clutter-in-emacsd-by-redirecting-files-to-emacsdvar)
- - [Customizations: Packages (post-init.el)](#customizations-packages-post-initel)
- - [Optimization: Native Compilation](#optimization-native-compilation)
- - [How to activate recentf, savehist, saveplace, and auto-revert?](#how-to-activate-recentf-savehist-saveplace-and-auto-revert)
- - [Activating autosave](#activating-autosave)
- - [auto-save-mode (Prevent data loss in case of crashes)](#auto-save-mode-prevent-data-loss-in-case-of-crashes)
- - [auto-save-visited-mode (Save file buffers after a few seconds of inactivity)](#auto-save-visited-mode-save-file-buffers-after-a-few-seconds-of-inactivity)
- - [Code completion with corfu](#code-completion-with-corfu)
- - [Configuring Vertico, Consult, and Embark](#configuring-vertico-consult-and-embark)
- - [Code folding](#code-folding)
- - [Changing the default theme](#changing-the-default-theme)
- - [Automatic removal of trailing whitespace on save](#automatic-removal-of-trailing-whitespace-on-save)
- - [Enhancing undo/redo](#enhancing-undoredo)
- - [Configuring Vim keybindings using Evil?](#configuring-vim-keybindings-using-evil)
- - [Configuring LSP Servers with Eglot (built-in)](#configuring-lsp-servers-with-eglot-built-in)
- - [Persisting and Restoring all buffers, windows/split, tab-bar, frames...](#persisting-and-restoring-all-buffers-windowssplit-tab-bar-frames)
- - [Configuring org-mode](#configuring-org-mode)
- - [Configuring markdown-mode (e.g., README.md syntax)](#configuring-markdown-mode-eg-readmemd-syntax)
- - [Tree-sitter Integration (Better Syntax Highlighting)](#tree-sitter-integration-better-syntax-highlighting)
- - [Auto upgrade Emacs packages](#auto-upgrade-emacs-packages)
- - [Safely terminating unused buffers](#safely-terminating-unused-buffers)
- - [Treemacs, a tree layout file explorer (Sidebar file explorer)](#treemacs-a-tree-layout-file-explorer-sidebar-file-explorer)
- - [Inhibit the mouse](#inhibit-the-mouse)
- - [Spell checker](#spell-checker)
- - [Efficient jumps for enhanced productivity](#efficient-jumps-for-enhanced-productivity)
- - [Asynchronous code formatting without cursor disruption](#asynchronous-code-formatting-without-cursor-disruption)
- - [Efficient template expansion with snippets](#efficient-template-expansion-with-snippets)
- - [A better Emacs *help* buffer](#a-better-emacs-help-buffer)
- - [Enhancing the Elisp development experience](#enhancing-the-elisp-development-experience)
- - [Showing the tab-bar](#showing-the-tab-bar)
- - [Changing the Default Font](#changing-the-default-font)
- - [Persist Text Scale](#persist-text-scale)
- - [Loading the custom.el file](#loading-the-customel-file)
- - [Which other customizations can be interesting to add?](#which-other-customizations-can-be-interesting-to-add)
- - [Customizations: pre-early-init.el](#customizations-pre-early-initel)
- - [Configuring straight.el](#configuring-straightel)
- - [Configuring Elpaca (package manager)](#configuring-elpaca-package-manager)
- - [Frequently asked questions](#frequently-asked-questions)
- - [Customizing Scroll Recentering](#customizing-scroll-recentering)
- - [How to display Emacs startup duration?](#how-to-display-emacs-startup-duration)
- - [How to get the latest version of all packages? (unstable)](#how-to-get-the-latest-version-of-all-packages-unstable)
- - [How to use MELPA stable?](#how-to-use-melpa-stable)
- - [How to load a local lisp file for machine-specific configurations?](#how-to-load-a-local-lisp-file-for-machine-specific-configurations)
- - [How to load Emacs customizations?](#how-to-load-emacs-customizations)
- - [How to increase gc-cons-threshold?](#how-to-increase-gc-cons-threshold)
- - [How to prevent Emacs from loading .dir-locals.el files?](#how-to-prevent-emacs-from-loading-dir-localsel-files)
- - [How to make minimal-emacs.d use an environment variable to change ~/.emacs.d to another directory?](#how-to-make-minimal-emacsd-use-an-environment-variable-to-change-emacsd-to-another-directory)
- - [Are post-early-init.el and pre-init.el the same file in terms of the logic?](#are-post-early-initel-and-pre-initel-the-same-file-in-terms-of-the-logic)
- - [Why is the menu bar disabled by default?](#why-is-the-menu-bar-disabled-by-default)
- - [Why did the author develop minimal-emacs.d?](#why-did-the-author-develop-minimal-emacsd)
- - [How to keep minimal-emacs.d pre-\*.el and post-\*.el files in a separate directory?](#how-to-keep-minimal-emacsd-pre-el-and-post-el-files-in-a-separate-directory)
- - [How to make *minimal-emacs.d* install packages in the early-init phase instead of the init phase?](#how-to-make-minimal-emacsd-install-packages-in-the-early-init-phase-instead-of-the-init-phase)
- - [Testimonials from users](#testimonials-from-users)
- - [Minimal-emacs.d configurations from users](#minimal-emacsd-configurations-from-users)
- - [Features](#features)
- - [Author and license](#author-and-license)
- - [Links](#links)
+ - [Introduction](#introduction)
+ - [Looking for the ideal starter kit to customize Emacs? You have found it.](#looking-for-the-ideal-starter-kit-to-customize-emacs-you-have-found-it)
+ - [Startup](#startup)
+ - [Install minimal-emacs.d](#install-minimal-emacsd)
+ - [Install minimal-emacs.d into `~/.emacs.d`](#install-minimal-emacsd-into-emacsd)
+ - [Alternative: Install minimal-emacs.d into `~/.minimal-emacs.d`](#alternative-install-minimal-emacsd-into-minimal-emacsd)
+ - [Update minimal-emacs.d](#update-minimal-emacsd)
+ - [Customizations: Never modify init.el and early-init.el. Modify these instead...](#customizations-never-modify-initel-and-early-initel-modify-these-instead)
+ - [Debug on error](#debug-on-error)
+ - [Customizations: UI (pre-early-init.el)](#customizations-ui-pre-early-initel)
+ - [How to enable the menu-bar, the tool-bar, dialogs, the contextual menu, and tooltips?](#how-to-enable-the-menu-bar-the-tool-bar-dialogs-the-contextual-menu-and-tooltips)
+ - [Reducing clutter in `~/.emacs.d` by redirecting files to `~/.emacs.d/var/`](#reducing-clutter-in-emacsd-by-redirecting-files-to-emacsdvar)
+ - [Customizations: Packages (post-init.el)](#customizations-packages-post-initel)
+ - [Optimization: Native Compilation](#optimization-native-compilation)
+ - [How to activate recentf, savehist, saveplace, and auto-revert?](#how-to-activate-recentf-savehist-saveplace-and-auto-revert)
+ - [Activating autosave](#activating-autosave)
+ - [auto-save-mode (Prevent data loss in case of crashes)](#auto-save-mode-prevent-data-loss-in-case-of-crashes)
+ - [auto-save-visited-mode (Save file buffers after a few seconds of inactivity)](#auto-save-visited-mode-save-file-buffers-after-a-few-seconds-of-inactivity)
+ - [Code completion with corfu](#code-completion-with-corfu)
+ - [Configuring Vertico, Consult, and Embark](#configuring-vertico-consult-and-embark)
+ - [Code folding](#code-folding)
+ - [Changing the default theme](#changing-the-default-theme)
+ - [Automatic removal of trailing whitespace on save](#automatic-removal-of-trailing-whitespace-on-save)
+ - [Enhancing undo/redo](#enhancing-undoredo)
+ - [Configuring Vim keybindings using Evil?](#configuring-vim-keybindings-using-evil)
+ - [Configuring LSP Servers with Eglot (built-in)](#configuring-lsp-servers-with-eglot-built-in)
+ - [Persisting and Restoring all buffers, windows/split, tab-bar, frames...](#persisting-and-restoring-all-buffers-windowssplit-tab-bar-frames)
+ - [Configuring org-mode](#configuring-org-mode)
+ - [Configuring markdown-mode (e.g., README.md syntax)](#configuring-markdown-mode-eg-readmemd-syntax)
+ - [Tree-sitter Integration (Better Syntax Highlighting)](#tree-sitter-integration-better-syntax-highlighting)
+ - [Auto upgrade Emacs packages](#auto-upgrade-emacs-packages)
+ - [Safely terminating unused buffers](#safely-terminating-unused-buffers)
+ - [Treemacs, a tree layout file explorer (Sidebar file explorer)](#treemacs-a-tree-layout-file-explorer-sidebar-file-explorer)
+ - [Inhibit the mouse](#inhibit-the-mouse)
+ - [Spell checker](#spell-checker)
+ - [Efficient jumps for enhanced productivity](#efficient-jumps-for-enhanced-productivity)
+ - [Asynchronous code formatting without cursor disruption](#asynchronous-code-formatting-without-cursor-disruption)
+ - [Efficient template expansion with snippets](#efficient-template-expansion-with-snippets)
+ - [A better Emacs *help* buffer](#a-better-emacs-help-buffer)
+ - [Enhancing the Elisp development experience](#enhancing-the-elisp-development-experience)
+ - [Showing the tab-bar](#showing-the-tab-bar)
+ - [Changing the Default Font](#changing-the-default-font)
+ - [Persist Text Scale](#persist-text-scale)
+ - [Loading the custom.el file](#loading-the-customel-file)
+ - [Which other customizations can be interesting to add?](#which-other-customizations-can-be-interesting-to-add)
+ - [Customizations: pre-early-init.el](#customizations-pre-early-initel)
+ - [Configuring straight.el](#configuring-straightel)
+ - [Configuring Elpaca (package manager)](#configuring-elpaca-package-manager)
+ - [Frequently asked questions](#frequently-asked-questions)
+ - [Customizing Scroll Recentering](#customizing-scroll-recentering)
+ - [How to display Emacs startup duration?](#how-to-display-emacs-startup-duration)
+ - [How to get the latest version of all packages? (unstable)](#how-to-get-the-latest-version-of-all-packages-unstable)
+ - [How to use MELPA stable?](#how-to-use-melpa-stable)
+ - [How to load a local lisp file for machine-specific configurations?](#how-to-load-a-local-lisp-file-for-machine-specific-configurations)
+ - [How to load Emacs customizations?](#how-to-load-emacs-customizations)
+ - [How to increase gc-cons-threshold?](#how-to-increase-gc-cons-threshold)
+ - [How to prevent Emacs from loading .dir-locals.el files?](#how-to-prevent-emacs-from-loading-dir-localsel-files)
+ - [How to make minimal-emacs.d use an environment variable to change ~/.emacs.d to another directory?](#how-to-make-minimal-emacsd-use-an-environment-variable-to-change-emacsd-to-another-directory)
+ - [Are post-early-init.el and pre-init.el the same file in terms of the logic?](#are-post-early-initel-and-pre-initel-the-same-file-in-terms-of-the-logic)
+ - [Why is the menu bar disabled by default?](#why-is-the-menu-bar-disabled-by-default)
+ - [Why did the author develop minimal-emacs.d?](#why-did-the-author-develop-minimal-emacsd)
+ - [How to keep minimal-emacs.d pre-\*.el and post-\*.el files in a separate directory?](#how-to-keep-minimal-emacsd-pre-el-and-post-el-files-in-a-separate-directory)
+ - [How to make *minimal-emacs.d* install packages in the early-init phase instead of the init phase?](#how-to-make-minimal-emacsd-install-packages-in-the-early-init-phase-instead-of-the-init-phase)
+ - [Testimonials from users](#testimonials-from-users)
+ - [Minimal-emacs.d configurations from users](#minimal-emacsd-configurations-from-users)
+ - [Features](#features)
+ - [Author and license](#author-and-license)
+ - [Links](#links)
From 87714bef466e0809f77e5112d5eeb70b7f002c16 Mon Sep 17 00:00:00 2001
From: James Cherti <60946298+jamescherti@users.noreply.github.com>
Date: Fri, 5 Sep 2025 17:36:39 -0400
Subject: [PATCH 24/30] Update README.md
---
README.md | 26 ++++++++++++++++++++++++++
1 file changed, 26 insertions(+)
diff --git a/README.md b/README.md
index 28422e5..e4c72fa 100644
--- a/README.md
+++ b/README.md
@@ -106,6 +106,7 @@ In addition to *minimal-emacs.d*, startup speed is influenced by your computer's
- [How to get the latest version of all packages? (unstable)](#how-to-get-the-latest-version-of-all-packages-unstable)
- [How to use MELPA stable?](#how-to-use-melpa-stable)
- [How to load a local lisp file for machine-specific configurations?](#how-to-load-a-local-lisp-file-for-machine-specific-configurations)
+ - [How to prevent Emacs from automatically recompiling some Elisp files?](#how-to-prevent-emacs-from-automatically-recompiling-some-elisp-files)
- [How to load Emacs customizations?](#how-to-load-emacs-customizations)
- [How to increase gc-cons-threshold?](#how-to-increase-gc-cons-threshold)
- [How to prevent Emacs from loading .dir-locals.el files?](#how-to-prevent-emacs-from-loading-dir-localsel-files)
@@ -2003,6 +2004,31 @@ This allows `local.el` to load, enabling custom configurations specific to the m
(Ensure that `local.el` is in the same directory as `post-init.el`.)
+### How to prevent Emacs from automatically recompiling some Elisp files?
+
+In some Emacs configurations, certain files may be repeatedly recompiled during startup or loading:
+```elisp
+Compiling /snap/emacs/current/usr/share/emacs/lisp/org/org-loaddefs.el.gz...
+Compiling /snap/emacs/current/usr/share/emacs/etc/themes/modus-vivendi-theme.el...
+```
+
+This happens because Emacs attempts native compilation on certain Elisp files. In many cases, you may want to prevent native compilation for specific files.
+
+You can configure Emacs to skip native compilation for files matching a list of regular expression patterns by setting `native-comp-jit-compilation-deny-list`. Here is an example:
+```elisp
+(let ((deny-list '("\\(?:[/\\\\]\\.dir-locals\\.el\\(?:\\.gz\\)?$\\)"
+ "\\(?:[/\\\\]modus-vivendi-theme\\.el\\(?:\\.gz\\)?$\\)"
+ "\\(?:[/\\\\][^/\\\\]+-loaddefs\\.el\\(?:\\.gz\\)?$\\)"
+ "\\(?:[/\\\\][^/\\\\]+-autoloads\\.el\\(?:\\.gz\\)?$\\)")))
+ (setq native-comp-jit-compilation-deny-list deny-list)
+ ;; Deprecated
+ (with-no-warnings
+ (setq native-comp-deferred-compilation-deny-list deny-list)
+ (setq comp-deferred-compilation-deny-list deny-list)))
+```
+
+This deny list causes Emacs to skip native compilation for files matching these patterns, avoiding unnecessary or problematic recompilation while allowing all other files to be compiled as usual.
+
### How to load Emacs customizations?
To load customizations saved by Emacs (`M-x customize`), add the following code snippet to the `post-init.el` file. This ensures that the custom file, typically set to a separate file for user preferences, is loaded without errors or messages during startup:
From 8d975e882026f1433086e6dcf86c1b9acaac61a1 Mon Sep 17 00:00:00 2001
From: James Cherti <60946298+jamescherti@users.noreply.github.com>
Date: Fri, 5 Sep 2025 17:42:41 -0400
Subject: [PATCH 25/30] Update README.md
---
README.md | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/README.md b/README.md
index e4c72fa..a2b4d04 100644
--- a/README.md
+++ b/README.md
@@ -106,7 +106,7 @@ In addition to *minimal-emacs.d*, startup speed is influenced by your computer's
- [How to get the latest version of all packages? (unstable)](#how-to-get-the-latest-version-of-all-packages-unstable)
- [How to use MELPA stable?](#how-to-use-melpa-stable)
- [How to load a local lisp file for machine-specific configurations?](#how-to-load-a-local-lisp-file-for-machine-specific-configurations)
- - [How to prevent Emacs from automatically recompiling some Elisp files?](#how-to-prevent-emacs-from-automatically-recompiling-some-elisp-files)
+ - [How to prevent Emacs from repeatedly recompiling some Elisp files?](#how-to-prevent-emacs-from-repeatedly-recompiling-some-elisp-files)
- [How to load Emacs customizations?](#how-to-load-emacs-customizations)
- [How to increase gc-cons-threshold?](#how-to-increase-gc-cons-threshold)
- [How to prevent Emacs from loading .dir-locals.el files?](#how-to-prevent-emacs-from-loading-dir-localsel-files)
@@ -2004,17 +2004,17 @@ This allows `local.el` to load, enabling custom configurations specific to the m
(Ensure that `local.el` is in the same directory as `post-init.el`.)
-### How to prevent Emacs from automatically recompiling some Elisp files?
+### How to prevent Emacs from repeatedly recompiling some Elisp files?
-In some Emacs configurations, certain files may be repeatedly recompiled during startup or loading:
+In certain Emacs configurations, specific files may be recompiled repeatedly during startup.
```elisp
Compiling /snap/emacs/current/usr/share/emacs/lisp/org/org-loaddefs.el.gz...
Compiling /snap/emacs/current/usr/share/emacs/etc/themes/modus-vivendi-theme.el...
```
-This happens because Emacs attempts native compilation on certain Elisp files. In many cases, you may want to prevent native compilation for specific files.
+This behavior arises because Emacs performs native compilation on specific Elisp files, and in many scenarios, it is desirable to prevent compilation of files that fail during the process.
-You can configure Emacs to skip native compilation for files matching a list of regular expression patterns by setting `native-comp-jit-compilation-deny-list`. Here is an example:
+Emacs can be configured to bypass native compilation for files whose paths match a list of regular expression patterns by setting `native-comp-jit-compilation-deny-list`. For example:
```elisp
(let ((deny-list '("\\(?:[/\\\\]\\.dir-locals\\.el\\(?:\\.gz\\)?$\\)"
"\\(?:[/\\\\]modus-vivendi-theme\\.el\\(?:\\.gz\\)?$\\)"
@@ -2027,7 +2027,7 @@ You can configure Emacs to skip native compilation for files matching a list of
(setq comp-deferred-compilation-deny-list deny-list)))
```
-This deny list causes Emacs to skip native compilation for files matching these patterns, avoiding unnecessary or problematic recompilation while allowing all other files to be compiled as usual.
+This deny list instructs Emacs to bypass native compilation for files matching the specified patterns, preventing unnecessary or error-prone recompilation while permitting all other files to be compiled normally.
### How to load Emacs customizations?
From c2883bb14064a09a4ad6e60563e3d43fa0185f92 Mon Sep 17 00:00:00 2001
From: James Cherti <60946298+jamescherti@users.noreply.github.com>
Date: Wed, 17 Sep 2025 16:00:53 -0400
Subject: [PATCH 26/30] Remove provide from init.el and early-init.el
---
early-init.el | 2 --
init.el | 2 --
2 files changed, 4 deletions(-)
diff --git a/early-init.el b/early-init.el
index f113cbb..5caa915 100644
--- a/early-init.el
+++ b/early-init.el
@@ -488,8 +488,6 @@ this stage of initialization."
;;; Load post-early-init.el
(minimal-emacs-load-user-init "post-early-init.el")
-(provide 'early-init)
-
;; Local variables:
;; byte-compile-warnings: (not obsolete free-vars)
;; End:
diff --git a/init.el b/init.el
index 9ad7a43..4f53dca 100644
--- a/init.el
+++ b/init.el
@@ -551,8 +551,6 @@
(minimal-emacs-load-user-init "post-init.el"))
(setq minimal-emacs--success t)
-(provide 'init)
-
;; Local variables:
;; byte-compile-warnings: (not obsolete free-vars)
;; End:
From be7fdce532cdf8d6ebbf8c0a1783463549a3ab28 Mon Sep 17 00:00:00 2001
From: James Cherti <60946298+jamescherti@users.noreply.github.com>
Date: Sun, 28 Sep 2025 15:02:38 -0400
Subject: [PATCH 27/30] Remove recentf-exclude
---
init.el | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/init.el b/init.el
index 4f53dca..5c4a9d7 100644
--- a/init.el
+++ b/init.el
@@ -218,9 +218,7 @@
(setq recentf-max-saved-items 300) ; default is 20
(setq recentf-max-menu-items 15)
(setq recentf-auto-cleanup 'mode)
-
-;; Update recentf-exclude
-(setq recentf-exclude (list "^/\\(?:ssh\\|su\\|sudo\\)?:"))
+(setq recentf-exclude nil)
;;; saveplace
From 05d4898f7f548386c97ab281e2c5813bd47b2a36 Mon Sep 17 00:00:00 2001
From: James Cherti <60946298+jamescherti@users.noreply.github.com>
Date: Fri, 5 Sep 2025 17:43:31 -0400
Subject: [PATCH 28/30] Update README.md
---
README.md | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/README.md b/README.md
index a2b4d04..0ba15e7 100644
--- a/README.md
+++ b/README.md
@@ -106,7 +106,7 @@ In addition to *minimal-emacs.d*, startup speed is influenced by your computer's
- [How to get the latest version of all packages? (unstable)](#how-to-get-the-latest-version-of-all-packages-unstable)
- [How to use MELPA stable?](#how-to-use-melpa-stable)
- [How to load a local lisp file for machine-specific configurations?](#how-to-load-a-local-lisp-file-for-machine-specific-configurations)
- - [How to prevent Emacs from repeatedly recompiling some Elisp files?](#how-to-prevent-emacs-from-repeatedly-recompiling-some-elisp-files)
+ - [How to prevent Emacs from repeatedly performing native compilation on specific Elisp files](#how-to-prevent-emacs-from-repeatedly-performing-native-compilation-on-specific-elisp-files)
- [How to load Emacs customizations?](#how-to-load-emacs-customizations)
- [How to increase gc-cons-threshold?](#how-to-increase-gc-cons-threshold)
- [How to prevent Emacs from loading .dir-locals.el files?](#how-to-prevent-emacs-from-loading-dir-localsel-files)
@@ -2004,7 +2004,7 @@ This allows `local.el` to load, enabling custom configurations specific to the m
(Ensure that `local.el` is in the same directory as `post-init.el`.)
-### How to prevent Emacs from repeatedly recompiling some Elisp files?
+### How to prevent Emacs from repeatedly performing native compilation on specific Elisp files
In certain Emacs configurations, specific files may be recompiled repeatedly during startup.
```elisp
From 238f41e79f1fe20f15a4c4cac5bdfac7f0659fb4 Mon Sep 17 00:00:00 2001
From: James Cherti <60946298+jamescherti@users.noreply.github.com>
Date: Sun, 7 Sep 2025 15:16:00 -0400
Subject: [PATCH 29/30] Update README.md
---
README.md | 14 ++++++--------
1 file changed, 6 insertions(+), 8 deletions(-)
diff --git a/README.md b/README.md
index 0ba15e7..ea791e9 100644
--- a/README.md
+++ b/README.md
@@ -1811,15 +1811,15 @@ And [add the Elpaca bootstrap code](https://github.com/progfolio/elpaca?tab=read
### Customizing Scroll Recentering
-By default, minimal-emacs.d sets `scroll-conservatively` to `101`:
+By default, minimal-emacs.d sets `scroll-conservatively` to `20`:
```emacs-lisp
-(setq scroll-conservatively 101) ; Default minimal-emacs.d value
+(setq scroll-conservatively 20) ; Default minimal-emacs.d value
```
-A value of `101` minimizes screen movement and maintains point visibility with minimal adjustment, which many users find optimal for rapid navigation.
+This makes Emacs recenters the window when the cursor moves past `scroll-conservatively` lines beyond the window edge.
-You can override this in your `post-init.el` file. Setting it to `0` forces Emacs to recenter the point aggressively, typically positioning it in the middle of the window:
+You can override this in your `post-init.el` file. Setting it to `0` forces Emacs to recenter the point aggressively, typically positioning it in the middle of the window (NOT RECOMMENDED):
```emacs-lisp
(setq scroll-conservatively 0) ; NOT RECOMMENDED. SET IT TO 101 INSTEAD.
@@ -1827,14 +1827,12 @@ You can override this in your `post-init.el` file. Setting it to `0` forces Emac
Although this offers more surrounding context, it results in frequent and pronounced screen movement, which can disrupt navigation. A value of `0` is generally discouraged unless this behavior is explicitly desired.
-Most users prefer `101`. Some select `10` as a compromise:
+A value of `101` minimizes screen movement and maintains point visibility with minimal adjustment:
```emacs-lisp
-(setq scroll-conservatively 10) ; Note: You might prefer 101 over 10.
+(setq scroll-conservatively 101)
```
-A value of `10` permits occasional recentering for additional context but introduces more movement than `101`.
-
### How to display Emacs startup duration?
To measure and display the time taken for Emacs to start, you can use the following Emacs Lisp function. This function will report both the startup duration and the number of garbage collections that occurred during initialization.
From a1536a757c83496bbf4b7e99ae932148bfe67fa7 Mon Sep 17 00:00:00 2001
From: James Cherti <60946298+jamescherti@users.noreply.github.com>
Date: Sun, 7 Sep 2025 15:19:23 -0400
Subject: [PATCH 30/30] Update README.md
---
README.md | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/README.md b/README.md
index ea791e9..55e36b4 100644
--- a/README.md
+++ b/README.md
@@ -1822,7 +1822,7 @@ This makes Emacs recenters the window when the cursor moves past `scroll-conserv
You can override this in your `post-init.el` file. Setting it to `0` forces Emacs to recenter the point aggressively, typically positioning it in the middle of the window (NOT RECOMMENDED):
```emacs-lisp
-(setq scroll-conservatively 0) ; NOT RECOMMENDED. SET IT TO 101 INSTEAD.
+(setq scroll-conservatively 0) ; NOT RECOMMENDED
```
Although this offers more surrounding context, it results in frequent and pronounced screen movement, which can disrupt navigation. A value of `0` is generally discouraged unless this behavior is explicitly desired.
@@ -1833,6 +1833,8 @@ A value of `101` minimizes screen movement and maintains point visibility with m
(setq scroll-conservatively 101)
```
+The main drawback of `101` is that Emacs will avoid recentering almost entirely, only adjusting the window just enough to keep point visible at the very top or very bottom of the screen. Point can stick to the top or bottom edge of the window, giving you very little context above or below, which can make editing harder if you want surrounding lines visible.
+
### How to display Emacs startup duration?
To measure and display the time taken for Emacs to start, you can use the following Emacs Lisp function. This function will report both the startup duration and the number of garbage collections that occurred during initialization.