From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Evans Winner Newsgroups: gmane.emacs.help Subject: Re: Change backup system Date: Mon, 28 Jul 2008 13:20:21 -0600 Organization: Aioe.org NNTP Server Message-ID: <8663qp7r4a.fsf@timbral.net> References: <3d30c6e7-d266-4b5b-a397-b9180a0acd88@y21g2000hsf.googlegroups.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1217274151 29629 80.91.229.12 (28 Jul 2008 19:42:31 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 28 Jul 2008 19:42:31 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Mon Jul 28 21:43:20 2008 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1KNYca-0005Z5-IC for geh-help-gnu-emacs@m.gmane.org; Mon, 28 Jul 2008 21:43:04 +0200 Original-Received: from localhost ([127.0.0.1]:46496 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KNYbg-0004UV-BY for geh-help-gnu-emacs@m.gmane.org; Mon, 28 Jul 2008 15:42:08 -0400 Original-Path: news.stanford.edu!headwall.stanford.edu!newsfeed.news2me.com!newsfeed.icl.net!newsfeed.fjserv.net!newsfeed.freenet.de!news.k-dsl.de!aioe.org!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 72 Original-NNTP-Posting-Host: tHL7Pw00KvzSeEbptdOqCQ.user.aioe.org Original-X-Complaints-To: abuse@aioe.org Cancel-Lock: sha1:YeAVNJNGFUU/zfYmyxh3RAeDZzc= User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (gnu/linux) Original-Xref: news.stanford.edu gnu.emacs.help:160650 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:55998 Archived-At: Florian Lindner writes: My idea is to copy the file to another folder. When I edit and save ~/ text/file.txt the backup is saved in ~/.emacs.d/backup/home/florian/ text/file.txt.n with n being a number incremted form 1 to x each save. I have a directory called ~/bu and this in my .emacs (thought I am not sure which versions of Emacs it works with): (setq version-control t) ; Numbered backups. (setq backup-directory-alist ; Backup directory `(("." . ,(expand-file-name "~/bu")))) I don't know if this is exactly what you mean.... I occasionally clean out old stuff from my ~/bu directory. The files are named like this: !home!thorne!hacking!litmus!mla.tmac.~3~ with bang-path kinda names and the number at the end a version number. Here is some documentation about those variables: ,----[ C-h v version-control RET ] | version-control is a variable defined in `/home/usr/local/share/emacs/23.0.60/lisp/files.elc'. | Its value is t | | This variable is safe as a file local variable if its value | satisfies the predicate `(lambda (x) (or (booleanp x) (equal x (quote never))))'. | | Documentation: | Control use of version numbers for backup files. | When t, make numeric backup versions unconditionally. | When nil, make them for files that have some already. | The value `never' means do not make them. | | You can customize this variable. `---- ,----[ C-h v backup-directory-alist RET ] | backup-directory-alist is a variable defined in `/home/usr/local/share/emacs/23.0.60/lisp/files.elc'. | Its value is | (("." . "/home/thorne/bu")) | | | Documentation: | Alist of filename patterns and backup directory names. | Each element looks like (REGEXP . DIRECTORY). Backups of files with | names matching REGEXP will be made in DIRECTORY. DIRECTORY may be | relative or absolute. If it is absolute, so that all matching files | are backed up into the same directory, the file names in this | directory will be the full name of the file backed up with all | directory separators changed to `!' to prevent clashes. This will not | work correctly if your filesystem truncates the resulting name. | | For the common case of all backups going into one directory, the alist | should contain a single element pairing "." with the appropriate | directory name. | | If this variable is nil, or it fails to match a filename, the backup | is made in the original file's directory. | | On MS-DOS filesystems without long names this variable is always | ignored. | | You can customize this variable. `----