Skip to content
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

Get cursor back to previous session's location #2104

Closed
mizzunet opened this issue Apr 14, 2022 · 1 comment
Closed

Get cursor back to previous session's location #2104

mizzunet opened this issue Apr 14, 2022 · 1 comment
Labels
C-enhancement Category: Improvements

Comments

@mizzunet
Copy link

mizzunet commented Apr 14, 2022

(I couldn't find if this has already been requested)

Describe your feature request

Save cursor location on quitting a file, then get back there when reopening it.
That is,

  1. Open a file, say main.go
  2. Be the cursor on some location, say 5:6
  3. Quit the file.
  4. Reopen main.go
  5. Set the cursor on location on previous session, that 5;6. Instead of at beginning(1:1)

I think this can be done the way mpv does to save and get previous playback position(--save-position-on-quit), which is by storing the location at ~/.config/mpv/watch_later/<some ID>

So, for this, a new config.toml, option save-position would be needed.

Thank you for this awesome editor (:

@mizzunet mizzunet added the C-enhancement Category: Improvements label Apr 14, 2022
@archseer
Copy link
Member

Duplicate of #401

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-enhancement Category: Improvements
Projects
None yet
Development

No branches or pull requests

2 participants