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

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

Re: Autosave and filename too long


From: Matt Muggeridge
Subject: Re: Autosave and filename too long
Date: Fri, 01 Nov 2002 01:48:53 GMT

Just a quick update.

Today I had the unfortunate situation of losing my connection mid-edits.
After reestablishing my environment and then opening the file, emacs did
automatically detect I had unsaved edits and prompted me to use
recover-file.  I did this, and it recovered the autosave filename.

All in all, I'm a happy camper - Thanks Michael!

I guess my attempt to test recovery before was not quite accurate.  When it
really counted, it worked!

Matt.

"Michael Slass" <miknrene@drizzle.com> wrote in message
news:m365vr22ak.fsf@localhost.localdomain...
> >> "Matt Muggeridge" <Matt.Muggeridge@hp.com> writes:
> >>
> >> I would like to try changing the "#" character to learn if it makes
> >> a difference.
> >>
> >> Thanks,
> >> Matt.
> >>
> >>
> >>"Michael Slass" <miknrene@drizzle.com> wrote in message
> >>news:m33cqwqufe.fsf@localhost.localdomain...
> >>
> >> (defadvice make-auto-save-file-name (after auto-save-remove-hash-mark
())
> >>   "return an autosave file name, replacing \"#\" with \"OCTOTHORPE\""
> >>   (setq ad-return-value
> >>         (replace-regexp-in-string "#" "OCTOTHORPE" ad-return-value)))
> >>
> >> (ad-activate 'make-auto-save-file-name)
> >>
> >>
> >> (defun auto-save-file-name-p (filename)
> >>   "Return non-nil if FILENAME can be yielded by
`make-auto-save-file-name'.
> >> FILENAME should lack slashes.  You can redefine this for
customization."
> >>   (string-match "^OCTOTHORPE.*OCTOTHORPE$" filename))
>
>
> "Matt Muggeridge" <Matt.Muggeridge@hp.com> writes:
>
> >Michael,
> >
> >Thanks for making the octothorpe go away!  The auto-save feature is now
> >working.
> >
> >On to the next hurdle...
> >
> >The recover feature of emacs is still searching for files of name
#foo.c#.
> >So after  a quick test, I tried to recover foo.c (I first verifed the
> >contents of "OCTOTHORPEfoo.cOCTOTHORPE" existed and contained 'lost'
edits).
> >The recover operation complained with:
> >
> >    Auto-save file /usr/users/muggerid/kingsx/#foo.c# not current
> >
> >Now that auto-save is working, what is needed to make recover aware of
this
> >new auto-save file name format?
> >
> >Matt.
>
>
> Hmmm... I'm not sure why that is, since recover-file uses
> make-auto-save-file-name to generate the recovery file name, so it
> should match.  I'll keep looking at it, but perhaps one of the gurus
> might have an idea?
>
> --
> Mike Slass




reply via email to

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