help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How to set 'buffer-save-without-query' from external program?


From: Thorsten Jolitz
Subject: Re: How to set 'buffer-save-without-query' from external program?
Date: Fri, 09 Nov 2012 18:32:49 +0100
User-agent: Gnus/5.130002 (Ma Gnus v0.2) Emacs/24.0.93 (gnu/linux)

"Drew Adams" <drew.adams@oracle.com> writes:

>> > You should be able to use (set-buffer-modified-p nil) to 
>> > prevent such checks.
>> 
>> But I want the buffer to be reverted and saved - only without being
>> queried. Would this still happen if I set the set-buffer-modified-p
>> flag to nil?
>
> Sorry, I don't have the time right now to get into it.
> Hopefully someone else can help more.
>
> But "revert and save" doesn't mean much to me.
> After reverting there is no need to save.
>
> Setting the modified-p flag just pretends that you have not modified
> the buffer. So you get no queries about wanting to save it.
>
> If you instead do want to save it, then just save it, systematically.

Ok, thanks for your help, I think this would do the job, but the error
is probably in the emacsclient call, because it does not take effect on
the buffer that should be closed without querying. 

If an external program opened a new emacsclient instance for editing,
and the file opened in the editing buffer is set as the input channel
for the external program - isn't that buffer automatically the target
buffer for further emacsclient calls that evaluate elisp code via the
"-e" option? 

-- 
cheers,
Thorsten




reply via email to

[Prev in Thread] Current Thread [Next in Thread]