summaryrefslogtreecommitdiff
path: root/config
diff options
context:
space:
mode:
authorSam Light <samlight1994@gmail.com>2025-05-29 22:46:08 +0100
committerSam Light <samlight1994@gmail.com>2025-05-29 22:46:08 +0100
commit38b43a176a0b24e985515de9c7df913675f587f3 (patch)
tree573482bb367e047470193ef48c73c55b614f089a /config
parent3fc135d11dfea3f84e95549c239376e85b6f8003 (diff)
Minor improvements and gitignore filesHEADmaster
Diffstat (limited to 'config')
-rw-r--r--config/editor.el14
-rw-r--r--config/lsp.el2
2 files changed, 12 insertions, 4 deletions
diff --git a/config/editor.el b/config/editor.el
index 677b4df..b032129 100644
--- a/config/editor.el
+++ b/config/editor.el
@@ -1,7 +1,7 @@
;; -*- lexical-binding: t; -*-
(use-package emacs
- :init
+ :config
;; Set all unicode
(set-charset-priority 'unicode)
(setq locale-coding-system 'utf-8
@@ -29,7 +29,13 @@
(global-subword-mode t)
- (add-hook 'prog-mode-hook (lambda () (modify-syntax-entry ?_ "_"))))
+ (add-hook 'prog-mode-hook (lambda () (modify-syntax-entry ?_ "_")))
+
+ ;; store all backup and autosave files in the tmp dir
+ (setq backup-directory-alist
+ `((".*" . ,temporary-file-directory)))
+ (setq auto-save-file-name-transforms
+ `((".*" ,temporary-file-directory t))))
;; meaningful names for buffers with the same name
(use-package uniquify
@@ -113,7 +119,9 @@
(([remap move-beginning-of-line] . crux-move-beginning-of-line)
("C-c o" . crux-open-with)
("C-<backspace>" . crux-kill-line-backwards)
- ([remap kill-whole-line] . crux-kill-whole-line)))
+ ([remap kill-whole-line] . crux-kill-whole-line))
+ :config
+ (crux-with-region-or-line kill-region))
;; nfkjbndfkb kdjbnkfjb
(use-package flyspell
diff --git a/config/lsp.el b/config/lsp.el
index 4103357..d925099 100644
--- a/config/lsp.el
+++ b/config/lsp.el
@@ -12,7 +12,7 @@
:custom
(lsp-keymap-prefix "C-c l") ; Prefix for LSP actions
- (lsp-completion-provider :none) ; Using Corfu as the provider
+ (lsp-completion-provider :capf) ; Using Corfu as the provider
(lsp-diagnostics-provider :flycheck)
(lsp-session-file (locate-user-emacs-file ".lsp-session"))
(lsp-log-io nil) ; IMPORTANT! Use only for debugging! Drastically affects performance