Install vim-lastplace by entering the following commands in the terminal:
sudo apt update sudo apt install vim-lastplace
Description:
Vim script to reopen files at your last edit position
Intelligently reopen files at your last edit position. By default git, svn, and mercurial commit messages are ignored because you probably want to type a new message and not re-edit the previous one.
Homepage: https://github.com/farmergreg/vim-lastplace
Version: 3.1.1-2
Section: universe/editors