summaryrefslogtreecommitdiff
path: root/nemacs-boilerplate.el
diff options
context:
space:
mode:
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)