[vim/vim] Add an option for using the jump list like tag stack (PR #13134)

32 views
Skip to first unread message

Yegappan Lakshmanan

unread,
Sep 20, 2023, 11:15:01 AM9/20/23
to vim/vim, Subscribed

I am not able to reopen the previous PR (#7738). So opening a new one.

Port the "jumpoptions" support from NeoVim:

https://neovim.io/doc/user/motion.html#jumplist-stack
neovim/neovim@39094b3
neovim/neovim#11530
https://vi.stackexchange.com/questions/18344/how-to-change-jumplist-behavior

Based on the feedback in the previous PR, it looks like many people like this option.

Bram wanted a much more elaborate infrastructure (similar to the undo tree) that is based on
timestamps to go back in time to different jump locations. This will take quite a bit of effort
to implement. So instead we can with this option for now.


You can view, comment on, or merge this pull request online at:

  https://github.com/vim/vim/pull/13134

Commit Summary

  • 8557022 Add an option for using jumplist like tag stack

File Changes

(10 files)

Patch Links:


Reply to this email directly, view it on GitHub.
You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/13134@github.com>

codecov[bot]

unread,
Sep 20, 2023, 11:27:56 AM9/20/23
to vim/vim, Subscribed

Codecov Report

Merging #13134 (8557022) into master (aa64ba1) will increase coverage by 0.59%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##           master   #13134      +/-   ##
==========================================
+ Coverage   82.13%   82.72%   +0.59%     
==========================================
  Files         160      150      -10     
  Lines      195239   182042   -13197     
  Branches    43815    40917    -2898     
==========================================
- Hits       160351   150587    -9764     
+ Misses      22050    18512    -3538     
- Partials    12838    12943     +105     
Flag Coverage Δ
huge-clang-Array 82.72% <100.00%> (-0.03%) ⬇️
linux 82.72% <100.00%> (-0.03%) ⬇️
mingw-x64-HUGE ?
mingw-x86-HUGE ?
windows ?

Flags with carried forward coverage won't be shown. Click here to find out more.

Files Changed Coverage Δ
src/mark.c 88.50% <100.00%> (-0.05%) ⬇️
src/optionstr.c 91.67% <100.00%> (+0.11%) ⬆️

... and 143 files with indirect coverage changes


Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/13134/c1727953215@github.com>

Christian Brabandt

unread,
Sep 20, 2023, 2:19:55 PM9/20/23
to vim/vim, Subscribed

thanks. sounds like there is some demand for this, so let me include this.


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/13134/c1728225249@github.com>

Christian Brabandt

unread,
Sep 20, 2023, 2:26:38 PM9/20/23
to vim/vim, Subscribed

Closed #13134 via 8701825.


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/13134/issue_event/10426491402@github.com>

Shane-XB-Qian

unread,
Sep 21, 2023, 8:42:15 AM9/21/23
to vim/vim, Subscribed

sounds like there is some demand for this,

not sure if i had readed or tried correctly, this seems made ctrl-i useless, was that really useful demand or it is a bug of this.


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/13134/c1729489790@github.com>

Shane-XB-Qian

unread,
Sep 21, 2023, 8:42:22 AM9/21/23
to vim/vim, Subscribed

sounds like there is some demand for this,

not sure if i read or tried correctly, this seems made ctrl-i useless, was that really a useful demand or it is a bug of this.


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/13134/c1729489812@github.com>

Yegappan Lakshmanan

unread,
Sep 21, 2023, 9:41:26 AM9/21/23
to vim/vim, Subscribed

sounds like there is some demand for this,

not sure if i read or tried correctly, this seems made ctrl-i useless, was that really a useful demand or it is a bug of this.

The CTRL-O/CTRL-I commands to browse the jump list still work. Note that without this option, if you go back
in the jump list using CTRL-O and then jump to a new location, the new jump location will be added to the end
of the jump list. Now if you press CTRL-O, it will go to a different location (confusing the users). With this option,
the jump list will behave like the tag stack. Please refer to the previous PR for the comments and also you can
try this option out in the latest Vim.


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/13134/c1729610211@github.com>

Yegappan Lakshmanan

unread,
Sep 21, 2023, 10:02:37 AM9/21/23
to vim/vim, Subscribed

There is a thread in Vi stack exchange about this: https://vi.stackexchange.com/questions/18344/how-to-change-jumplist-behavior


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/13134/c1729648962@github.com>

Shane-XB-Qian

unread,
Sep 22, 2023, 4:14:43 AM9/22/23
to vim/vim, Subscribed

as my understanding, the traditional one maybe a bit messed order after ctrl-o and new jump,
but this added 'stack' one may clear the record, i felt did not it make case be worse?
a.k.a bram said based on timestamp maybe was the right one IF really want to refine.


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/13134/c1731002019@github.com>

Christian Brabandt

unread,
Sep 22, 2023, 4:20:43 AM9/22/23
to vim/vim, Subscribed

Think of it as using the browser based forward/backward navigations.

This may actually make me use the jumplist, because I always found it to be too confusing where to jump next.

Yes a timestamp based navigation (similar to the undo-stack) may be even more desirable, but we then have to think about additional commands to navigate into the different branches (and it may still be confusing then)


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/13134/c1731011734@github.com>

Shane-XB-Qian

unread,
Sep 22, 2023, 4:33:39 AM9/22/23
to vim/vim, Subscribed

because I always found it to be too confusing where to jump next

yes, that traditional one sometime made me feel confused too,
but i may like keeping the jump list history there too, this added 'stack' one made me feel it worse.


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/13134/c1731030239@github.com>

Christian Brabandt

unread,
Sep 22, 2023, 4:47:03 AM9/22/23
to vim/vim, Subscribed

well, if you don't have to use this option.


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/13134/c1731048611@github.com>

Shane-XB-Qian

unread,
Sep 22, 2023, 5:07:17 AM9/22/23
to vim/vim, Subscribed

yes, i did not and would not set it.

but, hi, my point was let's keeping the style which bram or classic vim's style which preferred to add confirmed refined one, vs not a mid-stage of something, a.k.a not just someone said it is neovim or so-called IDE style then hurry to add it.
// and i doubt was this really a IDE style?


Reply to this email directly, view it on GitHub.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/13134/c1731076922@github.com>

Reply all
Reply to author
Forward
0 new messages