viewmail-info
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [VM] Specifying coding system for Imap.cache files


From: Uday S Reddy
Subject: Re: [VM] Specifying coding system for Imap.cache files
Date: Sun, 1 Jul 2012 00:41:17 +0100

blueman writes:

> When running vm on a Windows machine, I typically add ( "^C:/myhome/mail/"
> 'raw-text-unix) to the alist file-coding-system-alist since I want to keep
> all my mail files in the unix file system coding without the annoying
> carriage returns (^M) at the end of each line.
> 
> However, this doesn't seem to be working for the imap-cache folders even
> though they are stored in the same mail heirarchy...

First of all, VM doesn't set line ending formats.  Emacs does.

Secondly, the variable file-coding-system-alist, according to its
documentation, sets the coding system for *reading* files, not writing them.
So, it is a bad idea to set line-ending format there (or even one single
coding system for all types of files).  From what you write later on, I
suspect that your imap-cache folders might have gotten corrupted as a
result.

How Gnu Emacs decides the line ending format for the files it creates is a
bit of a mystery.  All I have in my customizations is 

(if running-fsf
    ;; (setq-default buffer-file-coding-system 'iso-latin-1-unix)
    (setq default-buffer-file-coding-system 'utf-8-unix)
  )

This seems to tell Emacs that it should use unix line endings all the time.
I can't be sure.  But I have never had Emacs create new files with DOS line
endings. 

Cheers,
Uday



reply via email to

[Prev in Thread] Current Thread [Next in Thread]