emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* org-src-fontification buffers
@ 2016-03-18 14:40 Alan Schmitt
  2016-03-18 15:40 ` Kyle Meyer
  0 siblings, 1 reply; 2+ messages in thread
From: Alan Schmitt @ 2016-03-18 14:40 UTC (permalink / raw)
  To: emacs-orgmode

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

Hello,

I'm having an issue with a buffer that is created by org for
fontification that wants to be saved, although it's temporary. In my
case, it's org-src-fontification:coq-mode, but it seems the problem
happens for other languages (see
https://emacs.stackexchange.com/questions/20593/org-src-fontify-natively-makes-magit-think-there-are-unsaved-files/20607)

Is there a way to tell emacs it's ok to kill this buffer without saving
it?

Thanks,

Alan

-- 
OpenPGP Key ID : 040D0A3B4ED2E5C7
Monthly Athmospheric CO₂ (2016-02, Mauna Loa Obs.): 404.02

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

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: org-src-fontification buffers
  2016-03-18 14:40 org-src-fontification buffers Alan Schmitt
@ 2016-03-18 15:40 ` Kyle Meyer
  0 siblings, 0 replies; 2+ messages in thread
From: Kyle Meyer @ 2016-03-18 15:40 UTC (permalink / raw)
  To: Alan Schmitt; +Cc: emacs-orgmode

Alan Schmitt <alan.schmitt@polytechnique.org> writes:

> Hello,
>
> I'm having an issue with a buffer that is created by org for
> fontification that wants to be saved, although it's temporary. In my
> case, it's org-src-fontification:coq-mode, but it seems the problem
> happens for other languages (see
> https://emacs.stackexchange.com/questions/20593/org-src-fontify-natively-makes-magit-think-there-are-unsaved-files/20607)

Trying with elisp blocks, I'm not able to reproduce this (pretty recent
Emacs 25, GNU/Linux, latest Org).

How are you calling save-some-buffers?  It should ignore buffers that
aren't visiting files unless its PRED argument is non-nil or a function
that returns non-nil.

Can you step through save-some-buffers and see what's going on there?
Specifically, what's passed in as PRED and what happens here?

    (or (not (functionp pred))
        (with-current-buffer buffer (funcall pred)))

> Is there a way to tell emacs it's ok to kill this buffer without saving
> it?

We could `(set-buffer-modified-p nil)', which will force
save-some-buffers to ignore it, but I don't think that should be
necessary.

-- 
Kyle

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2016-03-18 15:41 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-03-18 14:40 org-src-fontification buffers Alan Schmitt
2016-03-18 15:40 ` Kyle Meyer

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.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).