summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rw-r--r--init.org80
1 files changed, 44 insertions, 36 deletions
diff --git a/init.org b/init.org index 52f0d9e..32e3ec8 100644 --- a/init.org +++ b/init.org
@@ -33,17 +33,19 @@ After the first run, the above ~init.el~ will be replaced by the tangled stuff h
33 33
34#+NAME: tangle-on-save 34#+NAME: tangle-on-save
35#+BEGIN_SRC emacs-lisp :tangle no 35#+BEGIN_SRC emacs-lisp :tangle no
36 (defun acdw/tangle-init () 36 (defun acdw/tangle-init ()
37 "If the current buffer is `init.org', the code blocks are tangled, 37 "If the current buffer is `init.org', the code blocks are tangled,
38 and the tangled file is compiled." 38 and the tangled file is compiled and loaded."
39 (when (equal (buffer-file-name) 39 (when (equal (buffer-file-name)
40 (expand-file-name (concat user-emacs-directory "init.org"))) 40 (expand-file-name (concat user-emacs-directory "init.org")))
41 ;; Avoid running hooks when tangling. 41 ;; Avoid running hooks when tangling.
42 (let ((prog-mode-hook nil)) 42 (let ((prog-mode-hook nil))
43 (org-babel-tangle) 43 (org-babel-tangle)
44 (byte-compile-file (concat user-emacs-directory "init.el"))))) 44 (byte-compile-file (concat user-emacs-directory "init.el"))
45 (load-file (concat user-emacs-directory "early-init.el"))
46 (load-file (concat user-emacs-directory "init.el")))))
45 47
46(add-hook 'after-save-hook #'acdw/tangle-init) 48 (add-hook 'after-save-hook #'acdw/tangle-init)
47#+END_SRC 49#+END_SRC
48 50
49* Early initiation 51* Early initiation
@@ -122,7 +124,8 @@ Either way, I /do/ like the ~:custom~ interface that ~use-package~ has, so I've
122* Files 124* Files
123** [[https://github.com/emacscollective/no-littering][Keep .emacs.d tidy]] 125** [[https://github.com/emacscollective/no-littering][Keep .emacs.d tidy]]
124#+BEGIN_SRC emacs-lisp 126#+BEGIN_SRC emacs-lisp
125 (use-package no-littering) 127 (straight-use-package 'no-littering)
128 (require 'no-littering)
126#+END_SRC 129#+END_SRC
127** Customize 130** Customize
128I don't like the customize interface, but I still sometimes use it when I'm not sure what the name of a variable is. So I save the stuff to a file, I just don't load it or keep track of it. 131I don't like the customize interface, but I still sometimes use it when I'm not sure what the name of a variable is. So I save the stuff to a file, I just don't load it or keep track of it.
@@ -271,9 +274,7 @@ I hide all minor-modes by default for a clean modeline. However, I can add them
271#+BEGIN_SRC emacs-lisp 274#+BEGIN_SRC emacs-lisp
272 (use-package rich-minority 275 (use-package rich-minority
273 :custom 276 :custom
274 (rm-whitelist '("^$")) ; show no minor modes 277 (rm-whitelist '("^$")))
275 :config
276 (rich-minority-mode 1))
277#+END_SRC 278#+END_SRC
278** Fonts 279** Fonts
279I'm sure there's a better way to do this, but for now, this is the best I've got. I append to the ~face-font-family-alternatives~ because I don't know what kind of weird magic they're doing in there. 280I'm sure there's a better way to do this, but for now, this is the best I've got. I append to the ~face-font-family-alternatives~ because I don't know what kind of weird magic they're doing in there.
@@ -303,9 +304,13 @@ I'm sure there's a better way to do this, but for now, this is the best I've got
303 304
304*** [[https://github.com/rolandwalker/unicode-fonts][Unicode fonts]] 305*** [[https://github.com/rolandwalker/unicode-fonts][Unicode fonts]]
305#+BEGIN_SRC emacs-lisp 306#+BEGIN_SRC emacs-lisp
307 (use-package persistent-soft)
308
306 (use-package unicode-fonts 309 (use-package unicode-fonts
310 :after persistent-soft
307 :config 311 :config
308 (unicode-fonts-setup)) 312 (unicode-fonts-setup))
313
309#+END_SRC 314#+END_SRC
310* Editing 315* Editing
311** Completion 316** Completion
@@ -320,21 +325,36 @@ I was using company, but I think it might've been causing issues with ~awk-mode~
320 (cuss read-file-name-completion-ignore-case t) 325 (cuss read-file-name-completion-ignore-case t)
321#+END_SRC 326#+END_SRC
322** Selection & Minibuffer 327** Selection & Minibuffer
323*** Selectrum and Prescient for narrowing selection 328*** Ido
324#+BEGIN_SRC emacs-lisp 329#+begin_src emacs-lisp
325 (use-package selectrum 330 (use-package ido
331 :custom
332 (ido-everywhere t)
333 (ido-virtual-buffers t)
334 (ido-use-faces t)
335 (ido-default-buffer-method 'selected-window)
336 (ido-auto-merge-work-directories-length -1)
326 :config 337 :config
327 (selectrum-mode +1)) 338 (ido-mode 1))
328 339
329 (use-package prescient 340 (use-package flx-ido
341 :after ido
330 :config 342 :config
331 (prescient-persist-mode +1)) 343 (flx-ido-mode 1))
332 344
333 (use-package selectrum-prescient 345 (use-package ido-vertical-mode
334 :after (selectrum prescient) 346 :after ido
335 :config 347 :config
336 (selectrum-prescient-mode +1)) 348 (ido-vertical-mode 1))
337#+END_SRC 349
350 (use-package ido-completing-read+
351 :after ido
352 :custom
353 (ido-ubiquitous-max-items 50000)
354 (ido-cr+-max-items 50000)
355 :config
356 (ido-ubiquitous-mode 1))
357#+end_src
338*** CtrlF for searching 358*** CtrlF for searching
339#+BEGIN_SRC emacs-lisp 359#+BEGIN_SRC emacs-lisp
340 (use-package ctrlf 360 (use-package ctrlf
@@ -442,18 +462,6 @@ I was using company, but I think it might've been causing issues with ~awk-mode~
442 :config 462 :config
443 (add-to-list 'magit-no-confirm 'stage-all-changes)) 463 (add-to-list 'magit-no-confirm 'stage-all-changes))
444 464
445 ;; hook into `prescient'
446 (define-advice magit-list-refs
447 (:around (orig &optional namespaces format sortby)
448 prescient-sort)
449 "Apply prescient sorting when listing refs."
450 (let ((res (funcall orig namespaces format sortby)))
451 (if (or sortby
452 magit-list-refs-sortby
453 (not selectrum-should-sort-p))
454 res
455 (prescient-sort res))))
456
457 (when (executable-find "cmake") 465 (when (executable-find "cmake")
458 (use-package libgit) 466 (use-package libgit)
459 (use-package magit-libgit)) 467 (use-package magit-libgit))