33 (global-subword-mode t) ; move by camelCase words |
33 (global-subword-mode t) ; move by camelCase words |
34 (global-hl-line-mode t) ; highlight current line |
34 (global-hl-line-mode t) ; highlight current line |
35 (global-set-key (kbd "C-c c") 'compile) ; compile |
35 (global-set-key (kbd "C-c c") 'compile) ; compile |
36 (global-set-key (kbd "C-c r") 'recompile) ; recompile |
36 (global-set-key (kbd "C-c r") 'recompile) ; recompile |
37 (global-set-key (kbd "C-c a") 'align-regexp) ; align |
37 (global-set-key (kbd "C-c a") 'align-regexp) ; align |
38 (global-set-key (kbd "C-c g") 'rg) ; rg |
38 (global-set-key (kbd "C-c g") 'consult-ripgrep) ; ripgrep with preview |
39 |
39 |
40 |
40 |
41 ;;; ediff |
41 ;;; ediff |
42 (setq-default |
42 (setq-default |
43 ediff-split-window-function 'split-window-horizontally |
43 ediff-split-window-function 'split-window-horizontally |
62 (set-frame-font "Inconsolata-12" nil t)) |
62 (set-frame-font "Inconsolata-12" nil t)) |
63 |
63 |
64 |
64 |
65 ;;;; Packages ;;;; |
65 ;;;; Packages ;;;; |
66 (require 'package-require) |
66 (require 'package-require) |
67 (package-require '(rg company exec-path-from-shell expand-region flx-ido |
67 (package-require '(rg company exec-path-from-shell expand-region vertico |
68 smex magit magit-ido markdown-mode hgignore-mode move-text paredit |
68 orderless consult marginalia magit markdown-mode hgignore-mode move-text paredit |
69 rainbow-delimiters json-mode json-reformat flycheck |
69 rainbow-delimiters json-mode json-reformat flycheck |
70 solarized-theme terraform-mode visual-regexp yasnippet yaml-mode |
70 solarized-theme terraform-mode visual-regexp yasnippet yaml-mode |
71 zencoding-mode)) |
71 zencoding-mode)) |
72 |
72 |
73 ;; (custom-set-variables |
73 ;; (custom-set-variables |
145 (add-hook 'eshell-mode-hook |
145 (add-hook 'eshell-mode-hook |
146 (lambda () |
146 (lambda () |
147 (setenv "TERM" "emacs") |
147 (setenv "TERM" "emacs") |
148 (setenv "PAGER" "cat"))) |
148 (setenv "PAGER" "cat"))) |
149 |
149 |
150 ;;; ido / smex / completion |
150 ;;; vertico / orderless / consult / marginalia |
151 (setq-default |
151 (vertico-mode t) ; vertical completion UI |
152 ido-enable-flex-matching t ; fuzzy matching for ido mode |
152 (marginalia-mode t) ; annotations in completion |
153 ido-create-new-buffer 'always ; create new buffer without prompt |
153 (setq-default |
154 ido-max-window-height 1 ; max ido window height |
154 completion-styles '(orderless basic) ; orderless completion style |
155 ido-everywhere t ; use ido where possible |
155 completion-category-defaults nil |
156 ido-use-faces nil) |
156 completion-category-overrides '((file (styles partial-completion)))) |
157 (ido-mode t) ; file/buffer selector |
|
158 (flx-ido-mode t) |
|
159 (global-set-key (kbd "M-/") 'completion-at-point) |
157 (global-set-key (kbd "M-/") 'completion-at-point) |
160 (global-set-key (kbd "M-x") 'smex) |
158 (global-set-key (kbd "C-x b") 'consult-buffer) ; enhanced buffer switching |
161 (global-set-key (kbd "M-X") 'smex-major-mode-commands) |
159 (global-set-key (kbd "C-x 4 b") 'consult-buffer-other-window) |
|
160 (global-set-key (kbd "C-x 5 b") 'consult-buffer-other-frame) |
|
161 (global-set-key (kbd "M-y") 'consult-yank-pop) ; enhanced yank-pop |
162 |
162 |
163 |
163 |
164 ;;; emacs-lisp-mode |
164 ;;; emacs-lisp-mode |
165 (add-hook 'emacs-lisp-mode-hook 'enable-paredit-mode) |
165 (add-hook 'emacs-lisp-mode-hook 'enable-paredit-mode) |
166 |
166 |