help-gnu-emacs
[Top][All Lists]
Advanced

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

Re: version-control and make-backup-file-name-function


From: Florian Lindner
Subject: Re: version-control and make-backup-file-name-function
Date: Thu, 21 Aug 2008 12:16:36 -0700 (PDT)
User-agent: G2/1.0

On 19 Aug., 09:41, Kevin Rodgers <kevin.d.rodg...@gmail.com> wrote:
> FlorianLindnerwrote:
> > Hello,
>
> > I'm bringing this up again, since my question in the old thread [1]
> > produced no more answers...
>
> > I have a customized backup function:
>
> > (defun my-backup-file-name (fpath)
> >   (let (backup-root bpath)
> >     (setq backup-root "~/.emacs.d/backup")
> >     (setq bpath (concat backup-root fpath "~"))
> >     (make-directory (file-name-directory bpath) bpath)
> >     bpath
> >     )
> >   )
>
> > combinded with the backup settings:
>
> > (setq make-backup-file-name-function 'my-backup-file-name
> >       version-control t
> >       delete-old-versions t
> >       kept-new-versions 6
> >       kept-old-versions 2)
>
> > When uncommenting make-backup-file-name-function it works with backups
> > in the same dir as the original. With make-backup-file-name-function
> > there are backups in the .emacs/backup dir but only the first version
> > which is never updated. I suspect it's a problem with the creation of
> > the backup file name for the n-th version.
>
> > Anyone got an idea how to combine versioned backups and custom
> > location?
>
> Try setting backup-directory-alist instead of
> make-backup-file-name-function.

That puts all my backup files into one dir with the filename changed
to "dir1!dir2!file". Or can this be changed?

Thanks

Florian


reply via email to

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