Http://www.cnblogs.com/ini_always/archive/2012/03/03/2378554.html
Copy the VIM profile _VIMRC under Windows to your Mac and re-command it to. VIMRC, which is expected to implement a shared profile. But when I started vim, I reported not a editor command: ^m's error.
The essence of Mac OS is UNIX, and *nix's file line break is \ n, but Windows does not want to put \ r \ n as a newline character, so, when the VIM parsing from Windows copy to Mac VIMRC, because of encountering unresolved \ r, so error.
This simple, with Vim's God replacement function to deal with it:
:%S/^M//GC
The G option represents a global substitution, and the C option indicates that each substitution requires confirmation.
Note, however, that the ^m here are special characters and are not entered with the ^ and m two characters, but by two key combinations c-v c-m input (C = ctrl), and of course, ^m can also use \ r.
But strangely, after I have replaced it, I still report this error when I open vim. In Vim, take a closer look at the. vimrc file format or DOS format, and then use the following command to completely convert the file to UNIX format:
: Set Fileformat=unix
Well, save, and then start vim without errors.
"Reprint" Vim's E492 Error