-
Notifications
You must be signed in to change notification settings - Fork 0
Replace Current File with new File
vim-scripts/ReplaceFile
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
This is a mirror of http://www.vim.org/scripts/script.php?script_id=3636 Life-changing utility for saving files under new names in Vim with automated clean up of the old file's buffer and hard disk version. Usage: Call the function by one of the methods below. Insert the desired new /optional/newpath/filename and press <Enter>. The new file will be saved, a buffer for it will be opened, the old file's buffer closed and the old file deleted (if was written to disk). Method 1 (preferred): <leader>R brings up the function call with the current file's full path. Method 2: :Repfile will operate from Vim's CWD, not with the buffers directory. Mapping: The default mapping is: <leader>R If you want to change that, put let g:RepCall="yourmapping" in your vimrc. Added BufKill support to be able to delete/unload/wipeout a buffer without loosing it's window. Get BufKill here: vimscript#1147 (not neccessary, but really recommended)
About
Replace Current File with new File
Resources
Stars
Watchers
Forks
Packages 0
No packages published