2021-02-21 02:59:11 +00:00
|
|
|
;; -*- lexical-binding: t; -*-
|
|
|
|
|
2021-02-20 11:40:03 +00:00
|
|
|
;; Fix Emacs' bad defaults
|
2021-03-19 16:12:55 +00:00
|
|
|
(use-package emacs
|
|
|
|
:init
|
|
|
|
;; Save backups and autosaves in a centralized place
|
|
|
|
(defvar autosave-directory (expand-file-name "autosaves" user-emacs-directory))
|
|
|
|
(defvar backup-directory (expand-file-name "backups" user-emacs-directory))
|
|
|
|
(make-directory autosave-directory t)
|
|
|
|
(setq auto-save-file-name-transforms `((".*" ,autosave-directory t))
|
|
|
|
backup-directory-alist `(("." . ,backup-directory)))
|
2021-02-20 11:40:03 +00:00
|
|
|
|
2023-05-01 20:17:29 +00:00
|
|
|
(setq read-process-output-max (* 1024 1024))
|
2021-03-19 16:12:55 +00:00
|
|
|
(setq-default indent-tabs-mode nil)
|
2021-02-20 11:40:03 +00:00
|
|
|
|
2021-03-19 16:12:55 +00:00
|
|
|
;; Always display line numbers in text/programming modes
|
|
|
|
(add-hook 'prog-mode-hook #'display-line-numbers-mode)
|
2022-10-24 15:03:43 +00:00
|
|
|
(add-hook 'text-mode-hook #'display-line-numbers-mode)
|
|
|
|
:custom
|
2023-04-21 02:30:29 +00:00
|
|
|
(require-final-newline t)
|
2023-05-01 20:17:29 +00:00
|
|
|
(tab-always-indent 'complete)
|
|
|
|
(ring-bell-function 'ignore)
|
|
|
|
(enable-recursive-minibuffers t)
|
|
|
|
(vc-follow-symlinks t)
|
|
|
|
(display-line-numbers-type 'visual)
|
2024-05-02 13:26:03 +00:00
|
|
|
(even-window-sizes nil)
|
2024-08-14 00:15:07 +00:00
|
|
|
(fill-column 110)
|
|
|
|
(unique-buffer-name-style 'forward))
|
2023-05-01 20:17:29 +00:00
|
|
|
|
2021-02-20 11:40:03 +00:00
|
|
|
|
|
|
|
(provide 'init-defaults)
|