From: "Óscar Fuentes" <ofv@wanadoo.es>
To: help-gnu-emacs@gnu.org
Subject: Re: Disabling save-all-buffers on M-x compile
Date: Sat, 06 Feb 2010 02:20:24 +0100 [thread overview]
Message-ID: <871vgztb1j.fsf@telefonica.net> (raw)
In-Reply-To: 5e3a506e1002051329r1396d87wee16de97036fa18d@mail.gmail.com
Nathaniel Flath <flat0103@gmail.com> writes:
> When I do M-x compile, emacs prompts me about all unsaved files I have
> opened and whether I wish to save them. Is there a way to disable
> this so it goes straight to compilation?
There is the variable `compilation-ask-about-save'. If it is `nil', it
saves without prompting, but maybe this is not what you want.
Your other option is to define a `compile' replacement that does not
call `save-some-buffers':
(defun my-compile (command &optional comint)
(interactive
(list
(let ((command (eval compile-command)))
(if (or compilation-read-command current-prefix-arg)
(compilation-read-command command)
command))
(consp current-prefix-arg)))
(unless (equal command (eval compile-command))
(setq compile-command command))
;; (save-some-buffers (not compilation-ask-about-save) nil)
(setq-default compilation-directory default-directory)
(compilation-start command comint))
next prev parent reply other threads:[~2010-02-06 1:20 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-02-05 21:29 Disabling save-all-buffers on M-x compile Nathaniel Flath
2010-02-06 1:20 ` Óscar Fuentes [this message]
[not found] ` <mailman.782.1265419261.14305.help-gnu-emacs@gnu.org>
2010-02-06 3:38 ` despen
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=871vgztb1j.fsf@telefonica.net \
--to=ofv@wanadoo.es \
--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).