10

Quite often, when using CTRL-O to jump back to an older position, vim takes me to other files I've been editing previously. Is there a command, to go back within the jumplist just in the current file?

3 Answers 3

8

There is command that is close to what you need: g; will bring you back to older change position, g, will go forward to newer change position .

List of change position can be displayed with :changes.

7

My EnhancedJumps plugin offers separate special mappings that restrict the jump targets to only local locations (in the same buffer) and remote locations (only in other buffers).

1
  • Your answer is probably the correct one to my question, but tivn's answer feels more like the vim-way of accomplishing what I need to do. Thanks anyway!
    – SkWob
    Apr 28, 2015 at 10:00
1

Yes, backtick-backtick:

`` 

goes back to the previous mark (but only the previous mark) in the current buffer.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.