From 38797bfa5ef2759d8ae09035eee136273239a277 Mon Sep 17 00:00:00 2001 From: Lars Ingebrigtsen Date: Fri, 22 Apr 2022 14:34:50 +0200 Subject: [PATCH] Allow completion-ignore-case to be buffer-local * lisp/minibuffer.el (completing-read-default): Use the value of completion-ignore-case from the current buffer (bug#12615). --- lisp/minibuffer.el | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lisp/minibuffer.el b/lisp/minibuffer.el index e1947ae5ddb..198162266ee 100644 --- a/lisp/minibuffer.el +++ b/lisp/minibuffer.el @@ -4245,6 +4245,7 @@ See `completing-read' for the meaning of the arguments." ;; override bindings in base-keymap. base-keymap))) (buffer (current-buffer)) + (c-i-c completion-ignore-case) (result (minibuffer-with-setup-hook (lambda () @@ -4254,7 +4255,9 @@ See `completing-read' for the meaning of the arguments." (setq-local minibuffer-completion-confirm (unless (eq require-match t) require-match)) (setq-local minibuffer--require-match require-match) - (setq-local minibuffer--original-buffer buffer)) + (setq-local minibuffer--original-buffer buffer) + ;; Copy the value from original buffer to the minibuffer. + (setq-local completion-ignore-case c-i-c)) (read-from-minibuffer prompt initial-input keymap nil hist def inherit-input-method)))) (when (and (equal result "") def) -- 2.39.2