2022-12-29 21:41:21 -08:00
|
|
|
;;; EMACS early-init file -*- lexical-binding:t -*-
|
|
|
|
|
2023-01-06 23:36:09 -08:00
|
|
|
;; Manual implementation of gcmh as soon as possible (stolen from lambda emacs)
|
|
|
|
(setq gc-cons-threshold (* 300 1024 1024)) ; 300 MB
|
|
|
|
(defmacro k-time (&rest body)
|
|
|
|
"Measure and return the time it takes evaluating BODY."
|
|
|
|
`(let ((time (current-time)))
|
|
|
|
,@body
|
|
|
|
(float-time (time-since time))))
|
|
|
|
;; 15 sec gc loop when idle
|
|
|
|
(run-with-idle-timer 15 t
|
|
|
|
(lambda ()
|
|
|
|
(let ((inhibit-message t))
|
|
|
|
(message "Garbage Collector ran for %.06fsec"
|
|
|
|
(k-time (garbage-collect))))))
|
|
|
|
|
2022-12-29 21:41:21 -08:00
|
|
|
;; Set frame parameters early
|
2024-05-09 14:26:01 -07:00
|
|
|
(setq default-frame-alist '((font . "JetbrainsMono Nerd Font-11")
|
2023-01-12 21:45:32 -08:00
|
|
|
(tool-bar-lines . 0)
|
|
|
|
(menu-bar-lines . 0)
|
|
|
|
(vertical-scroll-bars . nil)))
|
2023-01-06 23:36:09 -08:00
|
|
|
|
|
|
|
;; Annoyoing comp errors
|
|
|
|
(setq native-comp-async-report-warnings-errors 'silent)
|
2023-02-18 22:07:57 -08:00
|
|
|
|
|
|
|
;; Annoying dialog boxes
|
|
|
|
(setq use-dialog-box nil)
|