summaryrefslogtreecommitdiff
path: root/nemacs-boilerplate.el
diff options
context:
space:
mode:
authorChristian Cunningham <cc@localhost>2024-05-28 11:19:22 -0700
committerChristian Cunningham <cc@localhost>2024-05-28 11:19:22 -0700
commitf14c2d3fe50de3c55e7c9684e93cdf5608a00b89 (patch)
treea8ea3bdb68779ecdce6d7be8b7d8f56a9ff3b4c1 /nemacs-boilerplate.el
Initial Commit
Diffstat (limited to 'nemacs-boilerplate.el')
-rw-r--r--nemacs-boilerplate.el17
1 files changed, 17 insertions, 0 deletions
diff --git a/nemacs-boilerplate.el b/nemacs-boilerplate.el
new file mode 100644
index 0000000..30841d1
--- /dev/null
+++ b/nemacs-boilerplate.el
@@ -0,0 +1,17 @@
+(setq gc-cons-threshold 402653184
+ gc-cons-percentage 0.6)
+
+(defvar startup/file-name-handler-alist file-name-handler-alist)
+(setq file-name-handler-alist nil)
+
+(defun startup/revert-file-name-handler-alist ()
+ (setq file-name-handler-alist startup/file-name-handler-alist))
+
+(defun startup/reset-gc ()
+ (setq gc-cons-threshold 16777216
+ gc-cons-percentage 0.1))
+
+(add-hook 'emacs-startup-hook 'startup/revert-file-name-handler-alist)
+(add-hook 'emacs-startup-hook 'startup/reset-gc)
+
+(provide 'nemacs-boilerplate)