Loading ...
Sorry, an error occurred while loading the content.

Re: vim: recover an unnamed file

Expand Messages
  • Gary Johnson
    ... For your unnamed buffers, there were no files, so there was nothing to back up. Regards, Gary -- -- You received this message from the vim_use maillist.
    Message 1 of 14 , May 17, 2013
    • 0 Attachment
      On 2013-05-17, ping wrote:
      > On 5/17/2013 1:36 AM, Gary Johnson wrote:
      > >On 2013-05-17, Ping wrote:
      > >
      > >>On May 16, 2013, at 10:41 PM, ping wrote:
      > >>
      > >>>On 5/16/2013 8:48 PM, Gary Johnson wrote:
      > >>>>After a quick look at Vim's memline.c, I think you are the victim of
      > >>>>poor housekeeping and a bug in Vim. You may still be able to
      > >>>>recover your files though.
      > >[...]
      > >
      > >>>>To your problem: It is quite likely that the same directories that
      > >>>>contain files named ".swa" also contain files named ".svz", ".svy",
      > >>>>and so on. Those are valid Vim swap files, but Vim doesn't
      > >>>>recognize them as such by those names.
      > >>>>
      > >>>>I would suggest first verifying that you do not care about the files
      > >>>>matching the pattern ".sw?", then delete them. Then find the newest
      > >>>>file with a name matching the pattern ".s??", rename it to ".swp",
      > >>>>and try recovering it.
      > >>>>
      > >>>>Once you've recovered all your files, I would suggest that you close
      > >>>>all instances of Vim and do a sweep of your file system using find
      > >>>>(not grep) to find all your swap files. Again be sure that you do
      > >>>>not need them, then delete them all. In the future, pay attention
      > >>>>to swap files left over after crashes and keep them cleaned up.
      > >>>thanks Gary, I think I only undertsand some part of your explanations.
      > >>>can you detail the steps for me to recover my file?
      > >>and, I just found that I had the swap file disabled :(
      > >That's unfortunate. Does that mean that you no longer need a better
      > >explanation?
      > >
      > >Regards,
      > >Gary
      > >
      >
      > I think for now there might be no way for me to get that back ,
      > since I clearly had this line in my vimrc:
      >
      > setlocal noswapfile "disable swapfile,
      >
      > I think I intentionlly did it for some purpose before .
      > one thing is I don't want to generate all of those aux files in like
      > a system folder .
      >
      > but after reading [more](http://my.opera.com/peterchenadded/blog/2008/12/27/gvim-7-1-swap-and-backup-files)
      >
      > I think I still should have the backup file turned on.
      >
      > backupdir=.,~/tmp,~/
      >
      > so I should still have my backup for unnamed files right?

      For your unnamed buffers, there were no files, so there was nothing
      to back up.

      Regards,
      Gary

      --
      --
      You received this message from the "vim_use" maillist.
      Do not top-post! Type your reply below the text you are replying to.
      For more information, visit http://www.vim.org/maillist.php

      ---
      You received this message because you are subscribed to the Google Groups "vim_use" group.
      To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@....
      For more options, visit https://groups.google.com/groups/opt_out.
    Your message has been successfully submitted and would be delivered to recipients shortly.