File tree 1 file changed +15
-8
lines changed
1 file changed +15
-8
lines changed Original file line number Diff line number Diff line change
1
+ (setq start-time (current-time ))
2
+
3
+ ; ; assign high memory to reduce gc during load
1
4
(setq gc-cons-threshold (* 50 1000 1000 ))
2
5
3
6
(add-hook 'after-init-hook (lambda ()
4
7
(add-to-list 'custom-theme-load-path " ~/.emacs.d/themes" )
5
8
(load-file (expand-file-name " config.el" user-emacs-directory))
6
9
(load-theme 'nord t )
7
- (setq gc-cons-threshold (* 2 1000 1000 ))
8
10
))
9
11
10
- (add-hook 'emacs-startup-hook
11
- (lambda ()
12
- (message " Emacs ready in %s with %d garbage collections. "
13
- (format " %. 2f seconds"
14
- (float-time
15
- (time-subtract after-init-time before-init-time)))
16
- gcs-done)))
12
+ (defun my/after-startup ()
13
+ (message " Emacs ready in %s with %d garbage collections. "
14
+ (format " %. 2f seconds"
15
+ (float-time
16
+ (time-subtract (current-time ) start-time)))
17
+ gcs-done)
18
+
19
+ ; ; set proper gc values after load
20
+ (setq gc-cons-threshold (* 2 1000 1000 ))
21
+ )
22
+
23
+ (add-hook 'emacs-startup-hook #'my/after-startup )
17
24
18
25
(require 'package )
19
26
(setq package-enable-at-startup nil )
You can’t perform that action at this time.
0 commit comments