Skip to main content

Questions tagged [undo-redo]

Question about navigation in the undo history, undoing, and redoing changes

0 votes
1 answer
55 views

I have a VimLeavePre autocmd, but it doesn't work as I intended. About the autocmd: i. On VimLeavePre, it will prompt for a location to store a Session.vim. ii. On getting such location, it tries to ...
N.W.'s user avatar
  • 1,860
0 votes
2 answers
77 views

There can be cases that one left some undo files here and there on some paths that may be also accessible by others. So how secure is an undofile? It seems that there is a checksum something to check ...
N.W.'s user avatar
  • 1,860
1 vote
2 answers
184 views

Vim provides udir for a centralized place for all undofiles, so I did set udir=UNDO, But I yet to know a way so that those undofiles can still work after refactoring. In my testing an undofile %Users%...
N.W.'s user avatar
  • 1,860
2 votes
1 answer
174 views

Is it possible for Neovim to understand vanilla Vim's undo (*~ & .*.un~) files? Even if I have vim.opt.undodir = vim.fn.expand("~/.config/nvim/undo") set in ~/.config/nvim/init.lua?
Geremia's user avatar
  • 1,063
0 votes
0 answers
43 views

I have this in my .vimrc " persistent undo even after closing if has('persistent_undo') if !isdirectory($HOME . '/.vim/backups') call mkdir($HOME . '/.vim/backups', 'p') endif set ...
Josh Friedlander's user avatar
0 votes
1 answer
103 views

I'm wondering if this is possible, I tried searching for APIs and asking LLMs how to do so. This line of lua makes an edit but is in the undo tree: vim.api.nvim_buf_set_lines(vim.api....
Oneechan69's user avatar
1 vote
1 answer
104 views

I usually want to delete empty spaces before the end of line, something than can be done easily with: :%s/\s\+$//g|'' But honestly I would like to do not include this change in the undolist, possibly ...
simzz's user avatar
  • 580
0 votes
1 answer
42 views

I use the undo functionality via u all the time and redo less frequently. I just now noticed, however, that the status bar reports change numbers, or perhaps buffer version numbers. [No Name] [+] ...
Greg Nisbet's user avatar
  • 1,951
1 vote
0 answers
129 views

I use vim with auto backups and persistent undo. I just lost a file, and I want to recover as much of it as possible. The backup contains most of the lost file, but the most recent changes are missing....
aky-her's user avatar
  • 163
2 votes
1 answer
96 views

For backup files, there's the option backupext for changing the extension of backups from filename.ext~ to (for example) filename.ext.bak by using set backupext=.bak in a vimrc file. Is there a ...
thruse's user avatar
  • 35
2 votes
1 answer
160 views

I am working through the user manual, doing the examples on a Mac using Vim (comes bundled with MacVim) on the terminal and was doing fine with undo (Chapter 2). Then with undo line or U, when doing ...
Miguel Cortes's user avatar
1 vote
2 answers
359 views

I accidentally removed about 1 hour of my work, how to restore? Last week I worked with file.md on my current computer and didn't save it into disk but just put my OS into a sleep mode. Yesterday I ...
Artyom's user avatar
  • 127
1 vote
0 answers
44 views

I have the following symbolic link for my ~/.vimrc ~/.vimrc -> ~/Dropbox/Backup/Dotfiles/.vimrc When I edit this file with vim ~/.vimrc, I see an undofile is created which looks like this: %Users%...
Matt's user avatar
  • 207
1 vote
1 answer
160 views

I use undotree to visualize the changes available in my undofile. Is it possible to merge a branch of the undofile with the current version of the file I am working on? I am looking for something ...
Matt's user avatar
  • 207
1 vote
1 answer
720 views

I am aware of the undofiles in Vim but they are binary and I don't know how to read them. I tries strings but it didn't help for my purpose. I am also aware of the :changes command but that only gives ...
yukashima huksay's user avatar

15 30 50 per page
1
2 3 4 5
7