Emacs Refcard: "Emacs reads DOS (end-of-line: \r\n) or Unix (end-of-line: \n) text files. It does not display the \r (or ^M) from DOS files, but marks tem with a \ in the mode line under DOS/Windows, and with (DOS) under other operating systems. (Under DOS Unix files are marked with (Unix) in the mode line.) Emacs is smart enough to write the file in the same way it was read. When you create a new file mit Emacs on Windows, it's a DOS type file. Which sucks when you save it via Samba to a Unix system, since it will contain ^M's. To save a buffer with Unix EOL format, type `C-x f unix C-x C-s'. Or add (add-untranslated-filesystem 'Z:\\mydir') to your .emacs, wich telles Emacs to write files for that file system (e.g. your Samba share) with Unix newlines."

0 Comments:
Post a Comment
<< Home