2023年の振り返り(Emacs編)

起動速度のこと init.elの初期化処理で時間がかかる事は起動後にやるようにした。 参考文書は定番とも言える下記2点。 Emacs の起動時間を""詰める"" Emacsを世界最速級で起動する方法 (defvar my/delayed-configs nil) (defvar my/delayed-config-timer nil) (eval-and-compile (defconst my/prio-low 1) (defconst my/prio-normal 10) (defconst my/prio-urgent 100)) (defun my/add-to-delayed-configs (priority config) "Add CONFIG with PRIORITY to delayed configs." (push (cons priority config) my/delayed-configs) ;; sort the configs by priority (setq my/delayed-configs (sort my/delayed-configs (lambda (a b) (> (car a) (car b)))))) (defun my/start-delayed-configs () "Execute `my/delayed-configs` list using a timer. Start a timer to run each config in the list with a default interval of 10ms....

December 30, 2023 · 2 min · 385 words · nekomimist