From: Michael Slass <miknrene@drizzle.com>
Subject: Re: Autosave and filename too long
Date: Thu, 24 Oct 2002 05:22:16 GMT [thread overview]
Message-ID: <m33cqwqufe.fsf@localhost.localdomain> (raw)
"Matt Muggeridge" <Matt.Muggeridge@hp.com> writes:
>Hi,
>
>My auto-save fails with the error:
>
> Auto-saving foo.c: Opening output file, file name too long:
>/usr/users/muggerid/kingsx/#foo.c#
>
>That is a filename of just 34 characters. My suspicion is that the '#'
>character is causing me problems, since "kingsx" is a mount point, which
>mount a VMS filesystem. In lieu of any other suggestions on how to fix
>this, I would like to try changing the "#" character to learn if it makes a
>difference.
>
>Thanks,
>Matt.
(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))
This advice will change "#" to "OCTOTHORPE" in the
auto-save-file-name, so you'll get save files like
/usr/users/muggerid/kingsx/OCTOTHORPEfoo.cOCTOTHORPE
That's much longer than you had, but doesn't contain the "#"
character, so you'll know right away if that was the culprit.
I've redefined auto-save-file-name-p (which you're allowed to do) so
that you can recover these auto-save-files.
--
Mike Slass
next reply other threads:[~2002-10-24 5:22 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-10-24 5:22 Michael Slass [this message]
2002-10-24 8:59 ` Autosave and filename too long Matt Muggeridge
2002-10-24 17:03 ` Michael Slass
2002-11-01 1:48 ` Matt Muggeridge
2002-11-01 2:23 ` Michael Slass
-- strict thread matches above, loose matches on Subject: below --
2002-10-24 1:13 Matt Muggeridge
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=m33cqwqufe.fsf@localhost.localdomain \
--to=miknrene@drizzle.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).