提问人:Abhishek Singh 提问时间:11/15/2023 更新时间:11/15/2023 访问量:23
E325: 注意 找到名为“.write.c.swp”的交换文件 [已关闭]
E325: ATTENTION Found a swap file by the name ".write.c.swp" [closed]
问:
描述
我在使用 vi 编辑器时遇到了一个问题。我正在编辑一个文件,不小心按下了它,它退出了文件,当我重新打开它时,我收到了以下错误:Ctrl + Z
E325: ATTENTION
Found a swap file by the name ".write.c.swp"
owned by: abhishek-singh dated: Wed Nov 15 12:52:18 2023
file name: ~abhishek-singh/sysCalls/write.c
modified: no
user name: abhishek-singh host name: BEAST
process ID: 646 (STILL RUNNING)
While opening file "write.c"
dated: Wed Nov 15 12:57:08 2023
NEWER than swap file!
(1) Another program may be editing the same file. If this is the case,
be careful not to end up with two different instances of the same
file when making changes. Quit, or continue with caution.
(2) An edit session for this file crashed.
If this is the case, use ":recover" or "vim -r write.c"
to recover the changes (see ":help recovery").
If you did this already, delete the swap file ".write.c.swp"
to avoid this message.
Swap file ".write.c.swp" already exists!
[O]pen Read-Only, (E)dit anyway, (R)ecover, (Q)uit, (A)bort:
重现步骤
- 在 vi 中打开文件
vi filename.txt
- 开始编辑。
- 按下可暂停该过程。
Ctrl+Z
- 重新打开文件。
我试过什么
我尝试了该命令,但导致以下错误::recover
Using swap file ".write.c.swp"
Original file "~/sysCalls/write.c"
E308: Warning: Original file may have been changed
E309: Unable to read block 1 from .write.c.swp
那么有人可以向我解释下一步该怎么做以及这条消息的真正含义吗?
答: 暂无答案
评论
Ctrl+Z
停止作业。不要再次打开文件,而是通过运行 将作业放回前台。vim
fg