From: Nikolay Kudryavtsev <nikolay.kudryavtsev@gmail.com>
To: npostavs@users.sourceforge.net
Cc: 25340@debbugs.gnu.org
Subject: bug#25340: Save-some-buffers gets called when installing packages.
Date: Thu, 5 Jan 2017 09:26:31 +0300 [thread overview]
Message-ID: <8a717ff8-c5f7-2b3e-33d0-0a0403dbddf5@gmail.com> (raw)
In-Reply-To: <87zij63z0j.fsf@users.sourceforge.net>
[-- Attachment #1: Type: text/plain, Size: 179 bytes --]
Oh, that's a better idea. Fixed the patch.
The question now is whether there's even a need to add a new arg to
byte-recompile-directory?
--
Best Regards,
Nikolay Kudryavtsev
[-- Attachment #2: 0001-Prevent-package-install-from-asking-to-save-buffers.patch --]
[-- Type: text/plain, Size: 1159 bytes --]
From ed64fe20726df039ad0a9bede2d1f4167ea607f9 Mon Sep 17 00:00:00 2001
From: Nikolay Kudryavtsev <nikolay.kudryavtsev@gmail.com>
Date: Thu, 5 Jan 2017 09:10:01 +0300
Subject: [PATCH] Prevent package-install from asking to save buffers
* lisp/emacs-lisp/bytecomp.el (byte-recompile-directory):
`save-some-buffers' is called only for files within that directory.
---
lisp/emacs-lisp/bytecomp.el | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/lisp/emacs-lisp/bytecomp.el b/lisp/emacs-lisp/bytecomp.el
index 63be7e2..db84973 100644
--- a/lisp/emacs-lisp/bytecomp.el
+++ b/lisp/emacs-lisp/bytecomp.el
@@ -1639,7 +1639,10 @@ byte-recompile-directory
(if arg (setq arg (prefix-numeric-value arg)))
(if noninteractive
nil
- (save-some-buffers)
+ (save-some-buffers nil
+ (lambda ()
+ (member (expand-file-name buffer-file-name)
+ (directory-files directory t))))
(force-mode-line-update))
(with-current-buffer (get-buffer-create byte-compile-log-buffer)
(setq default-directory (expand-file-name directory))
--
2.10.2.windows.1
next prev parent reply other threads:[~2017-01-05 6:26 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-01-02 22:42 bug#25340: Save-some-buffers gets called when installing packages Nikolay Kudryavtsev
2017-01-05 4:35 ` npostavs
2017-01-05 6:26 ` Nikolay Kudryavtsev [this message]
2017-01-06 2:31 ` npostavs
2017-01-07 18:06 ` Nikolay Kudryavtsev
2017-01-07 18:47 ` npostavs
2017-01-08 4:56 ` Nikolay Kudryavtsev
2017-01-08 5:33 ` npostavs
2017-01-08 8:06 ` Nikolay Kudryavtsev
2017-01-08 17:03 ` npostavs
[not found] ` <aa6168cc-d8eb-2c1c-70af-a63aed862b75@gmail.com>
2017-01-09 15:33 ` bug#25340: Fwd: " Noam Postavsky
2017-01-16 1:09 ` npostavs
2017-03-18 6:55 ` Tino Calancha
2017-03-04 10:18 ` Andreas Politz
2017-03-04 14:47 ` npostavs
2017-03-04 11:25 ` Andreas Politz
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=8a717ff8-c5f7-2b3e-33d0-0a0403dbddf5@gmail.com \
--to=nikolay.kudryavtsev@gmail.com \
--cc=25340@debbugs.gnu.org \
--cc=npostavs@users.sourceforge.net \
/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.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
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).