From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Michael Heerdegen Newsgroups: gmane.emacs.help Subject: Re: non-ASCII characters in auto-save files Date: Tue, 26 Jun 2012 00:40:36 +0200 Message-ID: <87fw9j582j.fsf@web.de> References: <4FE85DA0.7080201@cnrs-orleans.fr> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: dough.gmane.org 1340663919 18663 80.91.229.3 (25 Jun 2012 22:38:39 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Mon, 25 Jun 2012 22:38:39 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Tue Jun 26 00:38:38 2012 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1SjHva-0008Ki-2G for geh-help-gnu-emacs@m.gmane.org; Tue, 26 Jun 2012 00:38:38 +0200 Original-Received: from localhost ([::1]:50785 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SjHvZ-0006j7-U5 for geh-help-gnu-emacs@m.gmane.org; Mon, 25 Jun 2012 18:38:37 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:59472) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SjHvU-0006ir-4c for help-gnu-emacs@gnu.org; Mon, 25 Jun 2012 18:38:33 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SjHvP-0008K4-AA for help-gnu-emacs@gnu.org; Mon, 25 Jun 2012 18:38:31 -0400 Original-Received: from mout.web.de ([212.227.17.12]:61158) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SjHvP-0008Jn-0Q for help-gnu-emacs@gnu.org; Mon, 25 Jun 2012 18:38:27 -0400 Original-Received: from snow.dragon ([89.204.138.131]) by smtp.web.de (mrweb002) with ESMTPSA (Nemesis) id 0MPY5x-1SnytN33fl-005K8Z; Tue, 26 Jun 2012 00:38:25 +0200 In-Reply-To: (Peter Dyballa's message of "Mon, 25 Jun 2012 18:56:33 +0200") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.1.50 (gnu/linux) X-Provags-ID: V02:K0:CJ/DiSmnflo/fmQJk7m7nPCviBtXderC8LA3KETVUwS ReEAuS7ykyy3flkN+BP6GTHO9gfcAmRHLXCBtVM1EY+ty1BSe5 QQy5FJmJnn2pvsoBt0DaugTGr117mWRTcam7DvTibYmnjtkjCF G14j7L+tUjzfvIfw8E7kIdwpNcD2P9lsVB9w/ohXTFbSglBNi4 7aBV65Ir8iaF0PQmFrYSQ21c8lcAAjrTg2uQR2cP50= X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 212.227.17.12 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:85466 Archived-At: Peter Dyballa writes: > Am 25.06.2012 um 14:46 schrieb grivet: > > > I have two questions: > > - Can Emacs be persuaded to to encode auto-save files in a more > > useful manner ? > > - Is there a systematic way to convert #myfile# to iso-latin-9 > > (or iso-latin-1) code, other than painstakingly > > searching and replacing offending chars ? > > I have one answer: use file-local variables! > > For example in the header: > > %%% -*- mode: LaTeX; coding: iso-latin-9-unix; -*- > > Or in the (AUCTeX) footer: > > %%% Local Variables: > %%% mode: LaTeX > %%% fill-column: 99999 > %%% coding: iso-latin-9 > %%% End: > % I'm no expert here, but - that doesn't work for autosave files (try it!). Looking at the code, it seems that autosaving handles coding specially. File local variables are respected when finding the autosave file, but it is saved with a different encoding then the base file. But grivet: Why do you have to open those autosave files? I think the standard way to use them is via `recover-file' or `recover-session'. You shouldn't use them directly. Michael.