unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
From: "Christopher M. Miles" <numbchild@gmail.com>
To: Eli Zaretskii <eliz@gnu.org>
Cc: help-gnu-emacs@gnu.org
Subject: [SOLVED] Re: [NEED HELP] How to find out weird thing caused Emacs auto save scratch buffer as lot of files
Date: Tue, 23 May 2023 20:41:38 +0800	[thread overview]
Message-ID: <646cb8d4.170a0220.da3e1.b62e@mx.google.com> (raw)
In-Reply-To: <83h6s3pal0.fsf@gnu.org>

[-- Attachment #1: Type: text/plain, Size: 2392 bytes --]


Eli Zaretskii <eliz@gnu.org> writes:

>> From: "Christopher M. Miles" <numbchild@gmail.com>
>> Date: Tue, 23 May 2023 11:09:28 +0800
>> 
>> Recently I found in my user home directory, has lot of files named like:
>> 
>> #+begin_src sh
>> find ~ -maxdepth 1 -iregex ".*scratch.*" -print | head -n 8
>> echo ""
>> echo "Counted files number: "
>> find ~ -maxdepth 1 -iregex ".*scratch.*" -print | wc -l
>> #+end_src
>> 
>> #+RESULTS[(2023-05-23 11:18:44) aeb151fa27fcf758a5339bed5dc6617cb4f731ba]:
>> #+begin_example
>> /Users/stardiviner/#%2Ascratch%2A#UKK9EL#
>> /Users/stardiviner/#%2Ascratch%2A#4gsYFq#
>> /Users/stardiviner/#%2Ascratch%2A#ufEZRq#
>> /Users/stardiviner/#%2Ascratch%2A#XzrExY#
>> /Users/stardiviner/#%2Ascratch%2A#jGa6jP#
>> /Users/stardiviner/#%2Ascratch%2A#mweKr5#
>> /Users/stardiviner/#%2Ascratch%2A#mDmbh3#
>> /Users/stardiviner/#%2Ascratch%2A#CTbcQ7#
>> 
>> Counted files number: 
>>      321
>> #+end_example
>> 
>> - I tried search "scratch" in my Emacs config files, not found any clue.
>> - I tried to check out some minor modes like auto-save, savehist, etc. Not them neither.
>> - I tried to search "scratch" in my Emacs packages installation directory elpa/, still not found.
>> 
>> Does anybody have any clue how to debug this issue quickly?
>
> Do you have auto-save-mode enabled in the *scratch* buffer?  What does
>
>   M-: buffer-auto-save-file-name RET
>
> produce if you invoke it from the *scratch* buffer?  If it produces a
> non-nil value, you have somehow turned auto-save-mode in *scratch*.

I checked the *scratch* buffer status, indeed the `auto-save-mode` and
`auto-save-visited-mode` are enabled. And the value of variable
`buffer-auto-save-file-name` is: "/Users/stardiviner/#%2Ascratch%2A#lfiW0Q#"

Indeed found the problem! Hahaha, Thanks, Eli.

How to get around this problem? I disabled `auto-save-mode` now in my Emacs config now.

But I use git blame check out the `auto-save-mode` config lines, I
enabled it long time ago, but have not happened this problem before.

Anyway, problem solved now. Thanks a lot! Guys

-- 

[ stardiviner ]
I try to make every word tell the meaning that I want to express without misunderstanding.

Blog: https://stardiviner.github.io/
IRC(libera.chat, freenode): stardiviner, Matrix: stardiviner
GPG: F09F650D7D674819892591401B5DF1C95AE89AC3

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 487 bytes --]

      reply	other threads:[~2023-05-23 12:41 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-05-23  3:09 [NEED HELP] How to find out weird thing caused Emacs auto save scratch buffer as lot of files Christopher M. Miles
2023-05-23  8:54 ` Dr Rainer Woitok
2023-05-23  9:46   ` Christopher M. Miles
2023-05-23 11:10 ` Eli Zaretskii
2023-05-23 12:41   ` Christopher M. Miles [this message]

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=646cb8d4.170a0220.da3e1.b62e@mx.google.com \
    --to=numbchild@gmail.com \
    --cc=eliz@gnu.org \
    --cc=help-gnu-emacs@gnu.org \
    /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).