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

Missing numbers in undohistory #137

Open
PedroVSCoimbra opened this issue May 11, 2022 · 3 comments
Open

Missing numbers in undohistory #137

PedroVSCoimbra opened this issue May 11, 2022 · 3 comments

Comments

@PedroVSCoimbra
Copy link

Hello, I was editing a file and going to very old stages in the undo tree. But suddenly I could not see the hole history of changes. The history reset.

2022-05-11-@00-09-48-scrot

It used to show all the changes from 0 to 2600. What could have happened? Can I recover the file in this stated?

@mbbill
Copy link
Owner

mbbill commented May 11, 2022

you might want to check if you have set the undolevels somewhere. It's the maximum number of changes that can be undone. undotree.vim will not touch the undo history unless you type C and then double confirm by typing YES. This is unlikely to happen by accident, so I guess you might have just hit the maximum undo levels.

@PedroVSCoimbra
Copy link
Author

Well, probably. Do you know the behavior when we hit the maximum undo levels? Shouldn't it delete one by one?
In my case it delete like 2000 in one go.

I also think that it might have something to do with editing a text what was too early in the history and doing changes there. Is that a possibility?

@mbbill
Copy link
Owner

mbbill commented May 11, 2022

yeah the document for the setting sounds like it should delete the history once hitting the limit and maintaining a sliding window of the newest changes but I haven't tested it, and maybe it works differently in some situations idk. Do you have the undolevels set? or maybe some other plug-ins are messing with it?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants