blob: 7f80cac18161a8fab550b9ef532907fb33422226 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
|
;;; Dotfiles --- Jakub Dlugosz emacs config
;;; Commentary:
;;; Code:
(defvar jd-emacs/directory
(concat user-emacs-directory
"/jd-emacs/")
"Path to jd-emacs config directory.")
(defun jd-emacs/load (file-name)
"Load file from jd-emacs directory.
FILE-NAME - file name to load."
(let ((file (expand-file-name (concat jd-emacs/directory
"jd-emacs-" file-name ".el"))))
(load file)))
(setq gc-cons-threshold (* 2 1000 1000))
(defun jd/display-startup-time ()
(message "Emacs loaded in %s with %d garbage collections."
(format "%.2f seconds"
(float-time
(time-subtract after-init-time before-init-time)))
gcs-done))
(defun jd-emacs/startup ()
"This procedure will run after Emacs startup."
(electric-pair-mode 1)
(global-company-mode 1)
(jd/display-startup-time))
(setq gc-cons-threshold (* 50 1000 1000))
(add-hook 'emacs-startup-hook #'jd-emacs/startup)
(setq user-full-name "Jakub Dlugosz"
user-mail-address "jdlugosz963@gmail.com")
(setq backup-directory-alist '(("." . "~/.cache/emacs/backup"))
backup-by-copying t
version-control t
delete-old-versions t
kept-new-versions 20
kept-old-versions 5)
(setq user-emacs-directory "~/.cache/emacs")
(require 'package)
(setq package-archives '(("melpa" . "https://melpa.org/packages/")
("org" . "https://orgmode.org/elpa/")
("gnu-devel" . "https://elpa.gnu.org/devel/")
("elpa" . "https://elpa.gnu.org/packages/")))
(package-initialize)
(unless package-archive-contents
(package-refresh-contents))
(unless (package-installed-p 'use-package)
(package-install 'use-package))
(setq use-package-always-ensure t)
(add-to-list 'load-path (expand-file-name "~/.config/emacs/jd/"))
(require 'use-package)
(jd-emacs/load "keys")
(jd-emacs/load "ui")
(jd-emacs/load "org-mode")
(jd-emacs/load "dev")
(jd-emacs/load "apps")
(jd-emacs/load "custom")
(setq gc-cons-threshold (* 2 1000 1000))
;; jd-int.el ends here
|