Quantcast
Channel: How to save as a new file and keep working on the original one in Vim? - Stack Overflow
Viewing all articles
Browse latest Browse all 5

Answer by Jianwen W. for How to save as a new file and keep working on the original one in Vim?

$
0
0

Thanks for the answers. Now I know that there are two ways of "SAVE AS" in Vim.

Assumed that I'm editing hello.txt.

  • :w world.txt will write hello.txt's content to the file world.txt while keeping hello.txt as the opened buffer in vim.
  • :sav world.txt will first write hello.txt's content to the file world.txt, then close buffer hello.txt, finally open world.txt as the current buffer.

Viewing all articles
Browse latest Browse all 5

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>