Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

evil: make minibuffer evilification optional #7780

Open
4 tasks done
Atemu opened this issue Mar 30, 2024 · 0 comments
Open
4 tasks done

evil: make minibuffer evilification optional #7780

Atemu opened this issue Mar 30, 2024 · 0 comments
Labels
is:feature Adds or requests new features, or extends existing ones module:config/default Pertains to Doom's :config default module re:evil Related to vim/evil usage and users re:keybinds Changes to or discussion about Doom's keybinds

Comments

@Atemu
Copy link

Atemu commented Mar 30, 2024

I confirm that...

  • I have searched the issue tracker, documentation, FAQ, Discourse, and Google, in case this issue has already been reported/resolved.

  • I have read "How to Debug Issues", and will use it to provide as much information about this issue as possible.

  • The issue can be reproduced on the latest available commit of Doom.

  • The issue can be reproduced on a stable release of Emacs, such as 27, 28, or 29. (Unstable versions end in .50, .60, or .9x)

Expected behavior

I do not want my minibuffer evilifed but I do want +everywhere for major modes. There should be an option to leave the default key binds unmodified (e.g. +minibuffer).

I generally only want major mode evilification and leader keys.

Current behavior

Upstream evil-collection has evil-collection-setup-minibuffer for configuring that aspect but doom-emacs overrides it unconditionally:

(map! :map (evil-ex-completion-map evil-ex-search-keymap)
"C-a" #'evil-beginning-of-line
"C-b" #'evil-backward-char
"C-f" #'evil-forward-char
:gi "C-j" #'next-complete-history-element
:gi "C-k" #'previous-complete-history-element)
(define-key! :keymaps +default-minibuffer-maps
[escape] #'abort-recursive-edit
"C-a" #'move-beginning-of-line
"C-r" #'evil-paste-from-register
"C-u" #'evil-delete-back-to-indentation
"C-v" #'yank
"C-w" #'doom/delete-backward-word
"C-z" (cmd! (ignore-errors (call-interactively #'undo))))
(define-key! :keymaps +default-minibuffer-maps
"C-j" #'next-line
"C-k" #'previous-line
"C-S-j" #'scroll-up-command
"C-S-k" #'scroll-down-command)
;; For folks with `evil-collection-setup-minibuffer' enabled
(define-key! :states 'insert :keymaps +default-minibuffer-maps
"C-j" #'next-line
"C-k" #'previous-line)
(define-key! read-expression-map
"C-j" #'next-line-or-history-element
"C-k" #'previous-line-or-history-element))

Doom should either respect the upstream variable or have its own variable.

Related issue:

#6325

Steps to reproduce

  1. Open Emacs
  2. Want evil major modes and leader keys but default keybinds everywhere else
  3. Find no option to configure it

System Information

https://pastebin.com/z6czCYHp

@Atemu Atemu added is:bug Something isn't working as intended needs-triage Issue hasn't been assessed yet labels Mar 30, 2024
@hlissner hlissner added is:feature Adds or requests new features, or extends existing ones re:keybinds Changes to or discussion about Doom's keybinds module:config/default Pertains to Doom's :config default module re:evil Related to vim/evil usage and users and removed is:bug Something isn't working as intended needs-triage Issue hasn't been assessed yet labels Mar 30, 2024
@hlissner hlissner added this to the modules backlog milestone Mar 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
is:feature Adds or requests new features, or extends existing ones module:config/default Pertains to Doom's :config default module re:evil Related to vim/evil usage and users re:keybinds Changes to or discussion about Doom's keybinds
Projects
Status: Ready
Development

No branches or pull requests

2 participants