如何在 Vim 中另存为新文件并继续处理原始文件? [英] How to save as a new file and keep working on the original one in Vim?

查看:49
本文介绍了如何在 Vim 中另存为新文件并继续处理原始文件?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

每当我使用 :sav 命令时,它都会用新名称保存文件并打开在 Vim 中打开的新文件.

Whenever I use the :sav command, it saves the file with a new name and opens the new file open in Vim.

是否可以使用新名称保存文件但保持原始文件打开以进行编辑?

Is it possible to save the file with a new name but keep the original one open for editing?

推荐答案

使用带有文件名的 :w 命令:

Use the :w command with a filename:

:w other_filename

这篇关于如何在 Vim 中另存为新文件并继续处理原始文件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆