Implementing a jump stack

In my (currently unpublish edition/fork) of the Go extension, I’ve filled out the LSP functions for jumping to definition/type definition/implementations/references. I expect these all to become handled automatically for any language server that claims to support them, like Jump to Definition in did in Nova 2.

But I’m still using my own Jump to Definition in Nova 2 because all my Jump to commands push each jump onto a stack that I can quickly unwind with my UnJump command. So I started thinking about the feasibility of generalizing the jump stack as a standalone extension. At this point it I’m not seeing a good way of capturing a jump-stack-worthy event to push it on the stack, even though I can enumerate some general ideas about what user interactions should push something on.

Might there be something either on the roadmap, or something I’ve overlooked that would be useful for this? I use ^- all the time in VS Code, which usually does what I expect, though I admit haven’t carefully inspected the nuances of how it works.


I agree — the “jump back” command and shortcut might be the thing I miss the most from Sublime Text and VS Code.