Skip to content
This repository was archived by the owner on Oct 25, 2022. It is now read-only.
This repository was archived by the owner on Oct 25, 2022. It is now read-only.

conflicts with `evil-respect-visual-line-mode' #70

@ghost

Description

By default, evil-magit uses evil-next-visual-line and evil-previous-visual-line for movement, which is what I want, but for some reason this seems to conflict with enabling evil-respect-visual-line-mode. In my init.el, I have the following use-package declaration for evil:

(use-package evil
  :straight t
  :demand t
  :init
  ;; set before evil is loaded, as per evil docs
  (setq evil-respect-visual-line-mode t))

Normally, this configuration works, e.g. in a markdown buffer with visual-line-mode enabled. However, line-wise movement in magit-mode (e.g. an expanded diff) with visual-line-mode jumps between hard line breaks, as if evil-respect-visual-line-mode was never enabled. If I invoke M-x evil-next-visual-line it works fine, and tells me (incorrectly) that I can run it with 'j'. If I ask for what 'j' does run with M-x describe-key it says evil-next-line.
If I don't enable evil-respect-visual-line-mode then everything works as I would like, and line-wise movement properly accounts for visual-line-mode. Unfortunately, since evil-respect-visual-line-mode has to be set before evil is loaded, I can't disable it for magit-mode only. It's either globally enabled or disabled.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions