请教.swp如何恢复?
请教各位:我在验证linux(RDH9和RHEL4都试过)突然掉电后利用swp文件来恢复未保存过的文件时发现:如果vi后面不加文件名(加文件名已经搞定了),掉电后会产生一个.swp文件,文件类型为data,应该是个二进制文件。有时cat该文件能看到以前编辑的内容,却不知用什么方法能恢复该文件?请问哪位知道该如何恢复该文件?谢谢! [url]http://www.linuxpk.com/doc/vim/usr_11.html[/url] let say you have two files, myfile.txt and .myfile.txt.swp, to recover from your swp file, all you need to do is open the myfile.txt in vim and then it will ask you to select R option to recover your original file. After you select "R" option, you need to save your file and exit, and then delete the swp file.页:
[1]