about summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rw-r--r--init.el135
-rw-r--r--lisp/acdw-defaults.el45
2 files changed, 63 insertions, 117 deletions
diff --git a/init.el b/init.el index 3fcf374..0ef669f 100644 --- a/init.el +++ b/init.el
@@ -4,24 +4,23 @@
4 4
5;;; Code: 5;;; Code:
6 6
7;;; Remove when done bankrupting
8
9(defkeys t "C-x C-c" #'restart-emacs)
10
11;;; My extras 7;;; My extras
12 8
13(push (expand-file-name (locate-user-emacs-file "lisp")) load-path) 9(push (expand-file-name (locate-user-emacs-file "lisp")) load-path)
14(require 'acdw) ; Omnibus fun stuff 10(require 'acdw) ; Omnibus fun stuff
15 11
12;;; Remove when done bankrupting
13
14(defkeys t "C-x C-c" #'restart-emacs)
15
16;;; Basic defaults 16;;; Basic defaults
17 17
18(use-package no-littering 18(use-package no-littering
19 :ensure t 19 :ensure t :demand t
20 :demand t 20 :preface
21 (setq no-littering-etc-directory etc/
22 no-littering-var-directory var/)
21 :custom 23 :custom
22 (no-littering-etc-directory etc/)
23 (no-littering-var-directory var/)
24 (custom-file (etc/ "custom.el"))
25 (auto-save-file-name-transforms `(("." ,(var/ "auto-save/") t))) 24 (auto-save-file-name-transforms `(("." ,(var/ "auto-save/") t)))
26 (auto-save-list-file-prefix (var/ "auto-save/.saves-" t)) 25 (auto-save-list-file-prefix (var/ "auto-save/.saves-" t))
27 (backup-directory-alist `(("." . ,(var/ "backup/" t))))) 26 (backup-directory-alist `(("." . ,(var/ "backup/" t)))))
@@ -82,30 +81,28 @@
82;;; Completions 81;;; Completions
83 82
84(use-package vertico 83(use-package vertico
85 :ensure t 84 :ensure t :demand t
86 :custom 85 :custom
87 (resize-mini-windows 'grow-only) 86 (resize-mini-windows 'grow-only)
88 (vertico-cycle t) 87 (vertico-cycle t)
89 :init 88 :config
90 (use-package vertico-directory 89 (use-package vertico-directory
91 :after vertico 90 :after vertico
92 :config 91 :hook (rfn-eshadow-update-overlay-hook . vertico-directory-tidy))
93 (add-hook 'rfn-eshadow-update-overlay-hook #'vertico-directory-tidy))
94 (vertico-mode)) 92 (vertico-mode))
95 93
96(use-package marginalia 94(use-package marginalia
97 :ensure t 95 :ensure t :demand t
98 :demand t
99 :config 96 :config
100 (add-hook 'minibuffer-setup-hook #'truncate-lines-local-mode) 97 (add-hook 'minibuffer-setup-hook #'truncate-lines-local-mode)
101 (marginalia-mode)) 98 (marginalia-mode))
102 99
103(use-package orderless 100(use-package orderless
104 :ensure t 101 :ensure t :demand t
105 :custom 102 :config
106 (completion-styles '(orderless basic)) 103 (setc completion-styles '(orderless basic)
107 (completion-category-overrides 104 completion-category-overrides
108 '((file (styles basic partial-completion))))) 105 '((file (styles basic partial-completion)))))
109 106
110(use-package consult 107(use-package consult
111 :ensure t 108 :ensure t
@@ -158,7 +155,7 @@
158 (window-parameters (mode-line-format . none))))) 155 (window-parameters (mode-line-format . none)))))
159 156
160(use-package embark-consult 157(use-package embark-consult
161 :ensure t 158 :ensure t :demand t
162 :after (embark consult) 159 :after (embark consult)
163 :hook (embark-collect-mode-hook . consult-preview-at-point-mode)) 160 :hook (embark-collect-mode-hook . consult-preview-at-point-mode))
164 161
@@ -217,8 +214,7 @@
217 (advice-add 'text-scale-adjust :after #'visual-fill-column-adjust)) 214 (advice-add 'text-scale-adjust :after #'visual-fill-column-adjust))
218 215
219(use-package cape 216(use-package cape
220 :ensure t 217 :ensure t :demand t
221 :demand t
222 :init 218 :init
223 (dolist (fn '(cape-file cape-dabbrev)) 219 (dolist (fn '(cape-file cape-dabbrev))
224 (add-hook 'completion-at-point-functions fn 90)) 220 (add-hook 'completion-at-point-functions fn 90))
@@ -235,79 +231,27 @@
235 :bind (:map grep-mode-map 231 :bind (:map grep-mode-map
236 ("C-x C-q" . wgrep-change-to-wgrep-mode))) 232 ("C-x C-q" . wgrep-change-to-wgrep-mode)))
237 233
238(progn 234(use-package mlscroll
239 (use-package-statistics-gather :use-package 'mlscroll nil) 235 :ensure t :defer 1
240 (use-package-ensure-elpa 'mlscroll 236 :preface
241 '(t) 237 (defhook modus-themes-after-load-theme-hook
242 'nil) 238 :name modus-themes-load@mlscroll
243 (use-package-statistics-gather :preface 'mlscroll nil) 239 (mlscroll-mode -1)
244 (eval-and-compile 240 (when
245 (defhook modus-themes-after-load-theme-hook :name modus-themes-load@mlscroll 241 (or
246 (mlscroll-mode -1) 242 (memq 'modus-vivendi custom-enabled-themes)
247 (when 243 (memq 'modus-operandi custom-enabled-themes))
248 (or 244 (modus-themes-with-colors
249 (memq 'modus-vivendi custom-enabled-themes) 245 (setf mlscroll-in-color fg-dim mlscroll-out-color bg-inactive)))
250 (memq 'modus-operandi custom-enabled-themes)) 246 (eval-after 1
251 (modus-themes-with-colors 247 (mlscroll-mode 1)))
252 (setf mlscroll-in-color fg-dim mlscroll-out-color bg-inactive))) 248 :init
253 (eval-after 1 249 (when (daemonp)
254 (mlscroll-mode 1)))) 250 (add-hook 'server-after-make-frame #'modus-themes-load@mlscroll))
255 (defvar use-package--warning99 251 :config (modus-themes-load@mlscroll))
256 (function
257 (lambda
258 (keyword err)
259 (let
260 ((msg
261 (format "%s/%s: %s" 'mlscroll keyword
262 (error-message-string err))))
263 (display-warning 'use-package msg :error)))))
264 (condition-case-unless-debug err
265 (progn
266 (use-package-statistics-gather :init 'mlscroll nil)
267 (condition-case-unless-debug err
268 (when
269 (daemonp)
270 (add-hook 'server-after-make-frame
271 (function modus-themes-load@ml-scroll)))
272 (error
273 (funcall use-package--warning99 :init err)))
274 (run-with-idle-timer 1 nil
275 (function require)
276 'mlscroll nil t)
277 (eval-after-load 'mlscroll
278 '(progn
279 (use-package-statistics-gather :config 'mlscroll nil)
280 (let
281 ((now
282 (current-time)))
283 (message "%s..." "Configuring package mlscroll")
284 (prog1
285 (condition-case-unless-debug err
286 (progn
287 (modus-themes-load@mlscroll)
288 t)
289 (error
290 (funcall use-package--warning99 :config err)))
291 (let
292 ((elapsed
293 (float-time
294 (time-subtract
295 (current-time)
296 now))))
297 (if
298 (> elapsed 0.1)
299 (message "%s...done (%.3fs)" "Configuring package mlscroll" elapsed)
300 (message "%s...done" "Configuring package mlscroll")))))
301 (use-package-statistics-gather :config 'mlscroll t)))
302 (use-package-statistics-gather :init 'mlscroll t))
303 (error
304 (funcall use-package--warning99 :catch err)))
305 (use-package-statistics-gather :preface 'mlscroll t)
306 (use-package-statistics-gather :use-package 'mlscroll t))
307 252
308(use-package avy 253(use-package avy
309 :ensure t 254 :ensure t :demand t
310 :demand t
311 :custom 255 :custom
312 (avy-background t) 256 (avy-background t)
313 (avy-keys (string-to-list "asdfghjklqwertyuiopzxcvbnm")) 257 (avy-keys (string-to-list "asdfghjklqwertyuiopzxcvbnm"))
@@ -762,8 +706,7 @@
762;;; The INTERNET 706;;; The INTERNET
763 707
764(use-package link-hint 708(use-package link-hint
765 :ensure t 709 :ensure t :demand t
766 :demand t
767 :preface 710 :preface
768 (global-set-key (kbd "M-l") nil) 711 (global-set-key (kbd "M-l") nil)
769 :custom 712 :custom
diff --git a/lisp/acdw-defaults.el b/lisp/acdw-defaults.el index 80b2bcc..e4c9e14 100644 --- a/lisp/acdw-defaults.el +++ b/lisp/acdw-defaults.el
@@ -104,43 +104,46 @@
104 )) 104 ))
105 (funcall disable-mode -1)) 105 (funcall disable-mode -1))
106 106
107(deftheme use-package)
108(enable-theme 'use-package)
109
107;;; Internal packages 110;;; Internal packages
108 111
109(when (require 'abbrev nil t) 112(when (require 'abbrev nil t)
110 (custom-set-variables 113 (custom-theme-set-variables 'use-package
111 '(abbrev-file-name (sync/ "abbrev.el")) 114 '(abbrev-file-name (sync/ "abbrev.el"))
112 '(save-abbrevs 'silently))) 115 '(save-abbrevs 'silently)))
113 116
114(when (require 'autorevert nil t) 117(when (require 'autorevert nil t)
115 (custom-set-variables 118 (custom-theme-set-variables 'use-package
116 '(auto-revert-verbose nil) 119 '(auto-revert-verbose nil)
117 '(global-auto-revert-non-file-buffers t)) 120 '(global-auto-revert-non-file-buffers t))
118 (global-auto-revert-mode +1)) 121 (global-auto-revert-mode +1))
119 122
120(when (require 'comp nil t) 123(when (require 'comp nil t)
121 (custom-set-variables 124 (custom-theme-set-variables 'use-package
122 '(native-comp-async-report-warnings-errors 'silent) 125 '(native-comp-async-report-warnings-errors 'silent)
123 '(native-comp-deferred-compilation t))) 126 '(native-comp-deferred-compilation t)))
124 127
125(when (require 'custom nil t) 128(when (require 'custom nil t)
126 (custom-set-variables 129 (custom-theme-set-variables 'use-package
127 '(custom-file (etc/ "custom.el")))) 130 '(custom-file (etc/ "custom.el"))))
128 131
129(when (require 'ediff nil t) 132(when (require 'ediff nil t)
130 (custom-set-variables 133 (custom-theme-set-variables 'use-package
131 '(ediff-window-setup-function #'ediff-setup-windows-plain))) 134 '(ediff-window-setup-function #'ediff-setup-windows-plain)))
132 135
133(when (require 'eldoc nil t) 136(when (require 'eldoc nil t)
134 (custom-set-variables 137 (custom-theme-set-variables 'use-package
135 '(eldoc-echo-area-use-multiline-p nil) 138 '(eldoc-echo-area-use-multiline-p nil)
136 '(eldoc-idle-delay 0.1))) 139 '(eldoc-idle-delay 0.1)))
137 140
138(when (require 'executable nil t) 141(when (require 'executable nil t)
139 (custom-set-variables 142 (custom-theme-set-variables 'use-package
140 '(executable-prefix-env t))) 143 '(executable-prefix-env t)))
141 144
142(when (require 'files nil t) 145(when (require 'files nil t)
143 (custom-set-variables 146 (custom-theme-set-variables 'use-package
144 '(auto-save-default nil) 147 '(auto-save-default nil)
145 '(auto-save-interval 1) 148 '(auto-save-interval 1)
146 '(auto-save-no-message t) 149 '(auto-save-no-message t)
@@ -163,7 +166,7 @@
163 (auto-save-visited-mode)) 166 (auto-save-visited-mode))
164 167
165(when (require 'frame nil t) 168(when (require 'frame nil t)
166 (custom-set-variables 169 (custom-theme-set-variables 'use-package
167 '(blink-cursor-blinks 1) 170 '(blink-cursor-blinks 1)
168 '(blink-cursor-interval 0.25) 171 '(blink-cursor-interval 0.25)
169 '(blink-cursor-delay 0.25)) 172 '(blink-cursor-delay 0.25))
@@ -179,21 +182,21 @@
179 (add-hook 'ibuffer-mode-hook #'hl-line-mode)) 182 (add-hook 'ibuffer-mode-hook #'hl-line-mode))
180 183
181(when (require 'image nil t) 184(when (require 'image nil t)
182 (custom-set-variables 185 (custom-theme-set-variables 'use-package
183 '(image-use-external-converter 186 '(image-use-external-converter
184 (seq-some #'executable-find '("convert" "gm" "ffmpeg"))))) 187 (seq-some #'executable-find '("convert" "gm" "ffmpeg")))))
185 188
186(when (require 'imenu nil t) 189(when (require 'imenu nil t)
187 (custom-set-variables 190 (custom-theme-set-variables 'use-package
188 '(imenu-auto-rescan t))) 191 '(imenu-auto-rescan t)))
189 192
190(when (require 'isearch nil t) 193(when (require 'isearch nil t)
191 (custom-set-variables 194 (custom-theme-set-variables 'use-package
192 '(regexp-search-ring-max default-ring-max) 195 '(regexp-search-ring-max default-ring-max)
193 '(search-ring-max default-ring-max))) 196 '(search-ring-max default-ring-max)))
194 197
195(when (require 'minibuffer nil t) 198(when (require 'minibuffer nil t)
196 (custom-set-variables 199 (custom-theme-set-variables 'use-package
197 '(completion-category-defaults nil) 200 '(completion-category-defaults nil)
198 '(completion-category-overrides '((file (styles partial-completion)))) 201 '(completion-category-overrides '((file (styles partial-completion))))
199 '(completion-ignore-case t) 202 '(completion-ignore-case t)
@@ -209,13 +212,13 @@
209 (minibuffer-electric-default-mode)) 212 (minibuffer-electric-default-mode))
210 213
211(when (require 'mouse nil t) 214(when (require 'mouse nil t)
212 (custom-set-variables 215 (custom-theme-set-variables 'use-package
213 '(mouse-drag-copy-region t) 216 '(mouse-drag-copy-region t)
214 '(mouse-wheel-progressive-speed nil) 217 '(mouse-wheel-progressive-speed nil)
215 '(mouse-yank-at-point t))) 218 '(mouse-yank-at-point t)))
216 219
217(when (require 'paren nil t) 220(when (require 'paren nil t)
218 (custom-set-variables 221 (custom-theme-set-variables 'use-package
219 '(show-paren-delay 0.01) 222 '(show-paren-delay 0.01)
220 '(show-paren-style 'parenthesis) 223 '(show-paren-style 'parenthesis)
221 '(show-paren-when-point-in-periphery t) 224 '(show-paren-when-point-in-periphery t)
@@ -224,7 +227,7 @@
224 (electric-pair-mode)) 227 (electric-pair-mode))
225 228
226(when (require 'recentf nil t) 229(when (require 'recentf nil t)
227 (custom-set-variables 230 (custom-theme-set-variables 'use-package
228 '(recentf-save-file (var/ "recentf.el")) 231 '(recentf-save-file (var/ "recentf.el"))
229 '(recentf-max-menu-items default-ring-max) 232 '(recentf-max-menu-items default-ring-max)
230 '(recentf-max-saved-items nil) 233 '(recentf-max-saved-items nil)
@@ -236,7 +239,7 @@
236 (recentf-mode +1)) 239 (recentf-mode +1))
237 240
238(when (require 'savehist nil t) 241(when (require 'savehist nil t)
239 (custom-set-variables 242 (custom-theme-set-variables 'use-package
240 '(history-length 1024) 243 '(history-length 1024)
241 '(history-delete-duplicates t) 244 '(history-delete-duplicates t)
242 '(savehist-file (var/ "savehist.el")) 245 '(savehist-file (var/ "savehist.el"))
@@ -262,25 +265,25 @@
262 (savehist-mode +1)) 265 (savehist-mode +1))
263 266
264(when (require 'saveplace nil t) 267(when (require 'saveplace nil t)
265 (custom-set-variables 268 (custom-theme-set-variables 'use-package
266 '(save-place-file (var/ "places.el")) 269 '(save-place-file (var/ "places.el"))
267 '(save-place-forget-unreadable-files (eq system-type 'gnu/linux))) 270 '(save-place-forget-unreadable-files (eq system-type 'gnu/linux)))
268 (save-place-mode 1)) 271 (save-place-mode 1))
269 272
270(when (require 'uniquify nil t) 273(when (require 'uniquify nil t)
271 (custom-set-variables 274 (custom-theme-set-variables 'use-package
272 '(uniquify-after-kill-buffer-p t) 275 '(uniquify-after-kill-buffer-p t)
273 '(uniquify-buffer-name-style 'forward) 276 '(uniquify-buffer-name-style 'forward)
274 '(uniquify-ignore-buffers-re "^\\*") 277 '(uniquify-ignore-buffers-re "^\\*")
275 '(uniquify-separator path-separator))) 278 '(uniquify-separator path-separator)))
276 279
277(when (require 'vc nil t) 280(when (require 'vc nil t)
278 (custom-set-variables 281 (custom-theme-set-variables 'use-package
279 '(vc-follow-symlinks t) 282 '(vc-follow-symlinks t)
280 '(vc-make-backup-files t))) 283 '(vc-make-backup-files t)))
281 284
282(when (require 'window nil t) 285(when (require 'window nil t)
283 (custom-set-variables 286 (custom-theme-set-variables 'use-package
284 '(recenter-positions '(top 2 middle bottom)))) 287 '(recenter-positions '(top 2 middle bottom))))
285 288
286;;; New features 289;;; New features