about summary refs log tree commit diff stats
path: root/config.org
diff options
context:
space:
mode:
authorCase Duckworth2020-10-25 23:27:00 -0500
committerCase Duckworth2020-10-25 23:27:00 -0500
commite3882c6b9df3da405e05eee044d5205843b2c8a1 (patch)
tree132fbf055c4318e15f3438028e5009c585c3cd62 /config.org
parentChange init.org to config.org (diff)
downloademacs-e3882c6b9df3da405e05eee044d5205843b2c8a1.tar.gz
emacs-e3882c6b9df3da405e05eee044d5205843b2c8a1.zip
Switch back to selectrum and prescient
Diffstat (limited to 'config.org')
-rw-r--r--config.org56
1 files changed, 27 insertions, 29 deletions
diff --git a/config.org b/config.org index 3cebb79..8839462 100644 --- a/config.org +++ b/config.org
@@ -24,6 +24,7 @@ When this configuration is loaded for the first time, this ~init.el~ is loaded:
24 (require 'org) 24 (require 'org)
25 (find-file (concat user-emacs-directory "init.org")) 25 (find-file (concat user-emacs-directory "init.org"))
26 (org-babel-tangle) 26 (org-babel-tangle)
27 (load-file (concat user-emacs-directory "early-init.el"))
27 (load-file (concat user-emacs-directory "init.el")) 28 (load-file (concat user-emacs-directory "init.el"))
28 (byte-compile-file (concat user-emacs-directory "init.el")) 29 (byte-compile-file (concat user-emacs-directory "init.el"))
29#+END_SRC 30#+END_SRC
@@ -37,7 +38,7 @@ After the first run, the above ~init.el~ will be replaced by the tangled stuff h
37 "If the current buffer is `init.org', the code blocks are tangled, 38 "If the current buffer is `init.org', the code blocks are tangled,
38 and the tangled file is compiled and loaded." 39 and the tangled file is compiled and loaded."
39 (when (equal (buffer-file-name) 40 (when (equal (buffer-file-name)
40 (expand-file-name (concat user-emacs-directory "init.org"))) 41 (expand-file-name (concat user-emacs-directory "config.org")))
41 ;; Avoid running hooks when tangling. 42 ;; Avoid running hooks when tangling.
42 (let ((prog-mode-hook nil)) 43 (let ((prog-mode-hook nil))
43 (org-babel-tangle) 44 (org-babel-tangle)
@@ -328,35 +329,20 @@ I was using company, but I think it might've been causing issues with ~awk-mode~
328 (cuss read-file-name-completion-ignore-case t) 329 (cuss read-file-name-completion-ignore-case t)
329#+END_SRC 330#+END_SRC
330** Selection & Minibuffer 331** Selection & Minibuffer
331*** Ido 332*** Selectrum & Prescient
332#+begin_src emacs-lisp 333#+begin_src emacs-lisp
333 (use-package ido 334 (use-package selectrum
334 :custom 335 :config
335 (ido-everywhere t) 336 (selectrum-mode +1))
336 (ido-virtual-buffers t) 337
337 (ido-use-faces t) 338 (use-package prescient
338 (ido-default-buffer-method 'selected-window) 339 :config
339 (ido-auto-merge-work-directories-length -1) 340 (prescient-persist-mode +1))
340 :config 341
341 (ido-mode 1)) 342 (use-package selectrum-prescient
342 343 :after (selectrum prescient)
343 (use-package flx-ido 344 :config
344 :after ido 345 (selectrum-prescient-mode +1))
345 :config
346 (flx-ido-mode 1))
347
348 (use-package ido-vertical-mode
349 :after ido
350 :config
351 (ido-vertical-mode 1))
352
353 (use-package ido-completing-read+
354 :after ido
355 :custom
356 (ido-ubiquitous-max-items 50000)
357 (ido-cr+-max-items 50000)
358 :config
359 (ido-ubiquitous-mode 1))
360#+end_src 346#+end_src
361*** CtrlF for searching 347*** CtrlF for searching
362#+BEGIN_SRC emacs-lisp 348#+BEGIN_SRC emacs-lisp
@@ -464,6 +450,18 @@ I was using company, but I think it might've been causing issues with ~awk-mode~
464 :config 450 :config
465 (add-to-list 'magit-no-confirm 'stage-all-changes)) 451 (add-to-list 'magit-no-confirm 'stage-all-changes))
466 452
453 ;; hook into `prescient'
454 (define-advice magit-list-refs
455 (:around (orig &optional namespaces format sortby)
456 prescient-sort)
457 "Apply prescient sorting when listing refs."
458 (let ((res (funcall orig namespaces format sortby)))
459 (if (or sortby
460 magit-list-refs-sortby
461 (not selectrum-should-sort-p))
462 res
463 (prescient-sort res))))
464
467 (when (executable-find "cmake") 465 (when (executable-find "cmake")
468 (use-package libgit) 466 (use-package libgit)
469 (use-package magit-libgit)) 467 (use-package magit-libgit))