.emacs.d

the most bloated Emacs config on this planet
git clone https://git.trogloxene.org/.emacs.d.git
Log | Files | Refs

early-init.el (1545B)


      1 ;;; early-init.el --- early-init.el -*- lexical-binding: t -*-
      2 
      3 ;;; Commentary:
      4 
      5 ;;; Code:
      6 
      7 (if noninteractive
      8     (setq gc-cons-threshold #x8000000
      9           gc-cons-percentage 1.0)
     10   (setq gc-cons-threshold most-positive-fixnum))
     11 
     12 ;; from centaur emacs
     13 (let ((default-file-name-handler-alist file-name-handler-alist)
     14       (default-load-suffixes load-suffixes)
     15       (default-load-file-rep-suffixes load-file-rep-suffixes))
     16   (setq file-name-handler-alist nil
     17         load-suffixes '(".elc" ".el")
     18         load-file-rep-suffixes '(""))
     19   (add-hook 'emacs-startup-hook
     20             (lambda ()
     21               (setq load-suffixes default-load-suffixes
     22                     load-file-rep-suffixes default-load-file-rep-suffixes
     23                     file-name-handler-alist default-file-name-handler-alist))
     24             101))
     25 (when (boundp 'load-path-filter-function)
     26   (setq load-path-filter-function #'load-path-filter-cache-directory-files))
     27 (setq load-prefer-newer noninteractive)
     28 
     29 ;; benchmark-init
     30 (let ((benchmark-init-dir
     31        (expand-file-name "straight/build/benchmark-init" user-emacs-directory)))
     32   (when (file-exists-p benchmark-init-dir)
     33     (add-to-list 'load-path benchmark-init-dir)
     34     (require 'benchmark-init)
     35     (setq benchmark-init/backtrace-node-types '(require load))
     36     (benchmark-init/activate)))
     37 
     38 (setq package-enable-at-startup nil)
     39 
     40 (setq inhibit-startup-screen t)
     41 (when (fboundp 'tool-bar-mode)
     42   (tool-bar-mode -1)
     43   (scroll-bar-mode -1))
     44 (menu-bar-mode -1)
     45 
     46 (prefer-coding-system 'utf-8)
     47 ;;; early-init.el ends here