-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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
Moving to a fold with a 'gk' and then opening fold lands you on last line of fold #15490
Comments
I tried do reproduce the issue on Ubuntu 20.04.2 LTS and it worked as expected. Did you try reproducing this issue in another operating system? |
Unfortunately, I don't have easy access to a computer with a different operating system. I'll try in the next days and will report back when I do! |
It only happens with |
@jghauser can you verify that the settings are the same in vim and nvim. compare the output of:
(ignore the 'runtimepath' part) |
I finally got around to checking this. Running nvim:
vim:
Should I create a minimal init.vim/vimrc to try to force them both to the same settings? |
So, yes, a minimal |
Ok, I created such a init.vim and used it as the config for both vim and nvim. There are still some differences, but only very few. If I start vim with nvim:
vim (with -u init.vim):
The bug still occurs in the exact same fashion in both vim and nevoim. |
I never opened an issue on vim, not sure if anyone else did. |
… fold Problem: "gj" and "gk" do not move correctly over a closed fold. Solution: Use the same code as used for "j"/"k" to go to the next/previous line. (Luuk van Baal, closes vim/vim#12007) vim/vim@441a7a9 Fix neovim#15490
Neovim version (nvim -v)
NVIM v0.6.0-dev+182-ga373ca1d8
Vim (not Nvim) behaves the same?
yes, vim 8.2.2891
Operating system/version
Arch Linux
Terminal name/version
kitty 0.23.1
$TERM environment variable
xterm-kitty
Installation
AUR
How to reproduce the issue
nvim -u NORC test.txt
ornvim -u NONE text.txt
:set foldmethod=marker
G
gk
zo
Expected behavior
The cursor should (just as when moving up with
k
) be on the first line of the fold.Actual behavior
The cursor is on the last line of the fold.
The text was updated successfully, but these errors were encountered: