From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Glenn Morris Newsgroups: gmane.emacs.bugs Subject: auto save of remote files Date: Fri, 29 Mar 2002 14:51:27 +0000 Organization: None Sender: bug-gnu-emacs-admin@gnu.org Message-ID: NNTP-Posting-Host: localhost.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: main.gmane.org 1017413659 14198 127.0.0.1 (29 Mar 2002 14:54:19 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Fri, 29 Mar 2002 14:54:19 +0000 (UTC) Original-Received: from fencepost.gnu.org ([199.232.76.164]) by main.gmane.org with esmtp (Exim 3.33 #1 (Debian)) id 16qxli-0003gt-00 for ; Fri, 29 Mar 2002 15:54:18 +0100 Original-Received: from localhost ([127.0.0.1] helo=fencepost.gnu.org) by fencepost.gnu.org with esmtp (Exim 3.34 #1 (Debian)) id 16qxle-0005ow-00; Fri, 29 Mar 2002 09:54:14 -0500 Original-Received: from chx400.switch.ch ([130.59.10.2]) by fencepost.gnu.org with esmtp (Exim 3.34 #1 (Debian)) id 16qxj1-0005Ug-00 for ; Fri, 29 Mar 2002 09:51:31 -0500 Original-Received: from pegasus.csx.cam.ac.uk ([131.111.8.69]) by chx400.switch.ch with esmtp (Exim 3.20 #1) id 16qxiz-0003nm-00 for gnu-emacs-bug@moderators.isc.org; Fri, 29 Mar 2002 15:51:29 +0100 Original-Received: from news by pegasus.csx.cam.ac.uk with local (Exim 3.34 #1) id 16qxix-0001GE-00 for gnu-emacs-bug@moderators.isc.org; Fri, 29 Mar 2002 14:51:27 +0000 Original-To: gnu-emacs-bug@moderators.isc.org Original-Path: not-for-mail Original-Newsgroups: gnu.emacs.bug Original-Lines: 32 Original-NNTP-Posting-Host: xpc21.ast.cam.ac.uk X-Attribution: GM User-Agent: Gnus/5.090005 (Oort Gnus v0.05) Emacs/21.2 (i686-pc-linux-gnu) Errors-To: bug-gnu-emacs-admin@gnu.org X-BeenThere: bug-gnu-emacs@gnu.org X-Mailman-Version: 2.0.8 Precedence: bulk List-Help: List-Post: List-Subscribe: , List-Id: Bug reports for GNU Emacs, the Swiss army knife of text editors List-Unsubscribe: , List-Archive: Xref: main.gmane.org gmane.emacs.bugs:286 X-Report-Spam: http://spam.gmane.org/gmane.emacs.bugs:286 In emacs-21.2, `auto-save-file-name-transforms' is defined in files.el as follows: (defcustom auto-save-file-name-transforms `(("\\`/[^/]*:\\(.+/\\)*\\(.*\\)" ,(expand-file-name "\\2" temporary-file-directory))) " ... The default value is set up to put the auto-save file into the temporary directory (see the variable `temporary-file-directory') for editing a remote file." This means that a remote file of the form: /HOST:/dir1/foo.el will be transformed to /tmp/foo.el If one simultaneously edits a second remote file with the same basename, but in a different directory, for example: /HOST:/dir2/foo.el then it is transformed to the same local file. Maybe auto-save could use the same trick as `make-backup-file-name-1' here. When all backups are to be put in the same directory, they are converted as follows: /path/to/dir1/foo.el -> /path/to/backups/!path!to!dir1!foo.el