summary refs log tree commit diff
diff options
context:
space:
mode:
authorFranck Cuny <franck@fcuny.net>2022-10-24 07:57:53 -0700
committerFranck Cuny <franck@fcuny.net>2022-10-24 07:57:53 -0700
commitd86f470bbb10b796c1b3b2428e12027dcaf43145 (patch)
tree0986860954da024531ea2e5a40eab762781ff71f
parentref(rust): use eglot for lsp (diff)
downloademacs.d-d86f470bbb10b796c1b3b2428e12027dcaf43145.tar.gz
fix(Emacs): don't restore GC settings after loading init.el
A few commits ago, I changed the settings for GC in my LSP
configuration, as suggested by lsp-mode's performance guide. Then I
committed one of the cardinal sin of making a change: I did not check
that the setting was applied correctly after a restart of Emacs.

Yesterday while debugging some performance issue with eshell, I looked
into the GC, and realized that the setting was back to the default. This
was because of that block in init.el which restored the default once
init.el was loaded.

Drop this code, let's stick to the recommended settings by
lsp-mode (even if I don't use lsp-mode anymore).

Change-Id: Ia45bd10c67d397a72d92857ad206656c484baf8f
-rw-r--r--emacs/init.el3
1 files changed, 0 insertions, 3 deletions
diff --git a/emacs/init.el b/emacs/init.el
index 0b7f992..fcf2dbf 100644
--- a/emacs/init.el
+++ b/emacs/init.el
@@ -11,9 +11,6 @@
 (load custom-file)
 
 (setq gc-cons-threshold 64000000)
-(add-hook 'after-init-hook #'(lambda ()
-                               ;; restore after startup
-                               (setq gc-cons-threshold 800000)))
 
 ;; configure straight to manage packages
 (defvar bootstrap-version)