From ce4582d1bdcb2ddaebb7d751db426f9209e77c29 Mon Sep 17 00:00:00 2001 From: James Cherti <60946298+jamescherti@users.noreply.github.com> Date: Thu, 27 Feb 2025 10:12:37 -0500 Subject: [PATCH 1/4] Add remote-file-name-inhibit-delete-by-moving-to-trash --- init.el | 1 + 1 file changed, 1 insertion(+) diff --git a/init.el b/init.el index 0a0ac12..857f21e 100644 --- a/init.el +++ b/init.el @@ -130,6 +130,7 @@ ;; Delete by moving to trash in interactive mode (setq delete-by-moving-to-trash (not noninteractive)) +(setq remote-file-name-inhibit-delete-by-moving-to-trash t) ;; Disable the warning "X and Y are the same file". Ignoring this warning is ;; acceptable since it will redirect you to the existing buffer regardless. From 0768ad04abdb339d45bce0397c1660d468f42db3 Mon Sep 17 00:00:00 2001 From: James Cherti <60946298+jamescherti@users.noreply.github.com> Date: Thu, 27 Feb 2025 10:19:25 -0500 Subject: [PATCH 2/4] Enhance native-comp and warnings defaults --- README.md | 2 -- early-init.el | 5 +++++ 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index e6758f5..9ee8155 100644 --- a/README.md +++ b/README.md @@ -727,8 +727,6 @@ And [add the elpaca bootstrap code](https://github.com/progfolio/elpaca?tab=read 2. You can also add the following to `~/.emacs.d/post-init.el`: ```emacs-lisp -;; Hide warnings and display only errors -(setq warning-minimum-level :error) ;; Display of line numbers in the buffer: ;; (display-line-numbers-mode 1) diff --git a/early-init.el b/early-init.el index a455b1a..8f536f9 100644 --- a/early-init.el +++ b/early-init.el @@ -107,6 +107,8 @@ minimalistic appearance during startup.") ;; Set-language-environment sets default-input-method, which is unwanted. (setq default-input-method nil) +(setq warning-minimum-level (if minimal-emacs-debug :warning :error)) + ;;; Performance ;; Font compacting can be very resource-intensive, especially when rendering @@ -251,6 +253,9 @@ minimalistic appearance during startup.") ;; Suppress compiler warnings and don't inundate users with their popups. (setq native-comp-async-report-warnings-errors (or minimal-emacs-debug 'silent)) +(setq native-comp-verbose (if minimal-emacs-debug 1 0) + native-comp-debug (if minimal-emacs-debug 1 0)) +(setq native-comp-jit-compilation t) (setq native-comp-warning-on-missing-source minimal-emacs-debug) (setq debug-on-error minimal-emacs-debug From 1aab3d72578a321f9373f0244b4768c8bb427402 Mon Sep 17 00:00:00 2001 From: James Cherti <60946298+jamescherti@users.noreply.github.com> Date: Thu, 27 Feb 2025 10:30:57 -0500 Subject: [PATCH 3/4] Enhance scrolling and buffer processes --- init.el | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) diff --git a/init.el b/init.el index 857f21e..2cbb22f 100644 --- a/init.el +++ b/init.el @@ -20,15 +20,15 @@ ;;; Before package ;; Increase how much is read from processes in a single chunk -(setq read-process-output-max (* 1024 1024)) ; 1024kb +(setq read-process-output-max (* 2 1024 1024)) ; 1024kb + +(setq process-adaptive-read-buffering nil) ;; Don't ping things that look like domain names. (setq ffap-machine-p-known 'reject) ;;; Undo/redo -;; Increase undo limits to prevent early garbage collection from aggressively -;; truncating undo history (setq undo-limit (* 13 160000) undo-strong-limit (* 13 240000) undo-outer-limit (* 13 24000000)) @@ -115,8 +115,7 @@ ;; but may reduce visual feedback. (setq redisplay-skip-fontification-on-input t) -;; Collects and displays all available documentation immediately, even if -;; multiple sources provide it. It concatenates the results. +;; Collects and displays all available documentation immediately (setq eldoc-documentation-strategy 'eldoc-documentation-compose-eagerly) ;; Disable truncation of printed s-expressions in the message buffer @@ -232,9 +231,7 @@ ;;; savehist ;; `savehist-mode' is an Emacs feature that preserves the minibuffer history -;; between sessions. It saves the history of inputs in the minibuffer, such as -;; commands, search strings, and other prompts, to a file. This allows users to -;; retain their minibuffer history across Emacs restarts. +;; between sessions. (setq history-length 300) (setq savehist-save-minibuffer-history t) ;; Default @@ -277,7 +274,7 @@ ;; window is never automatically recentered. The default value of 0 triggers ;; recentering too aggressively. Setting it to 10 reduces excessive recentering ;; and only recenters the window when scrolling significantly off-screen. -(setq scroll-conservatively 10) +(setq scroll-conservatively 101) ;; Enables smooth scrolling by making Emacs scroll the window by 1 line whenever ;; the cursor moves off the visible screen. From 2c31d233e048bda095d2e4c2b5bbad12d8411d2f Mon Sep 17 00:00:00 2001 From: James Cherti <60946298+jamescherti@users.noreply.github.com> Date: Thu, 27 Feb 2025 15:26:38 -0500 Subject: [PATCH 4/4] Closes #33: Add savehist-additional-variables --- init.el | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/init.el b/init.el index 2cbb22f..5fc7c02 100644 --- a/init.el +++ b/init.el @@ -234,6 +234,11 @@ ;; between sessions. (setq history-length 300) (setq savehist-save-minibuffer-history t) ;; Default +(setq savehist-additional-variables + '(kill-ring ; clipboard + register-alist ; macros + mark-ring global-mark-ring ; marks + search-ring regexp-search-ring)) ; searches ;;; Frames and windows