hlissner / evil-snipe

2-char searching ala vim-sneak & vim-seek, for evil-mode
MIT License
341 stars 25 forks source link

Failed to jump to the last character in a buffer #49

Closed dvzubarev closed 7 years ago

dvzubarev commented 7 years ago

Hi, I use emacs-25.1.2 on Ubuntu 16.04 Steps to reproduce:

  1. M-x evil-mode
  2. eval in scratch buffer
    (evil-snipe-override-mode 1)
    (setq evil-snipe-scope 'whole-visible)
  3. Then try to jump to the last character in the buffer press f) and then f multiple times.
  4. Cursor is in the end of the first line "...mode 1)|"

I expect that cursor will be in the end of the second line "...whole-visible)|"

hlissner commented 7 years ago

Ack, sorry for the late reponse: I'm unable to reproduce this. Do you have any other configuration for evil-snipe? What is evil-snipe-repeat-keys set to? Are you getting any error messages (see view-echo-messages-area)?

dvzubarev commented 7 years ago

I use default configuration and only those two settings. I can reproduce it using emacs -Q with clean .emacs.d:

  1. paste
    (require 'package)
    (add-to-list 'package-archives '("melpa" . "http://melpa.org/packages/"))
    (package-initialize)

    to scratch buffer.

  2. select it and run M-x eval-region.
  3. run commands:
    M-x package-refresh-contents
    M-x package-install RET evil
    M-x package-install RET evil-snipe
  4. M-x evil-mode
  5. paste in scratch buffer and select
    (evil-snipe-override-mode 1)
    (setq evil-snipe-scope 'whole-visible)

    then run M-x eval-region.

  6. Then try to jump to the last character in the buffer press f) and then f multiple times.
  7. Cursor is in the end of the line "(evil-snipe-override-mode 1)|"

More info:

evil-snipe-repeat-keys is a variable defined in ‘evil-snipe.el’.
Its value is t

Echo area contains user-error: Can’t find ).

If there is an empty line after (setq evil-snipe-scope 'whole-visible) I can not reproduce this error too.

hlissner commented 7 years ago

I managed to reproduce it, and pushed a fix. Let me know if you still have the problem!