Skip to content

Remove redundant Vim swap files from the swap directory

License

Notifications You must be signed in to change notification settings

haphut/vim-trimswap

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 

Repository files navigation

vim-trimswap

Remove redundant Vim swap files from the swap directory.

vim-trimswap will remove each swap file that contains no changes in comparison to the original, manually saved file and that is not in use by a running process.

Assumptions for correct behavior

  • Vim uses only one directory for swap files, e.g. with set directory=~/.vim/swap// in vimrc.
  • The output of vim -r is in English and in UTF-8.
  • vim -r does not detect modified swap files as unmodified.
  • vim -r does not detect active swap files as inactive.
    • It does happen that swap files are falsely detected to be handled by a running process, though. That is why vim-trimswap might not remove all expected files.

Usage

Run vim-trimswap to remove redundant swap files.

About

Remove redundant Vim swap files from the swap directory

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages