unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
From: Kevin Rodgers <kevinr@ihs.com>
Subject: Re: Always reread some files
Date: Mon, 02 Dec 2002 15:26:37 -0700	[thread overview]
Message-ID: <3DEBDE1D.6070209@ihs.com> (raw)
In-Reply-To: mailman.1038584611.10208.help-gnu-emacs@gnu.org

Frédéric Bothamy wrote:

> * arthur.chereau <arthur.chereau@voila.fr> [2002-11-29 15:25] :
> 
>>>>I always want to reread those files.
>>>>
>>>auto-revert-mode
>>>
>>>
>>Unfortunately this doesn't work because the *.log files buffers are opened immediately after their modification, that is:
>>- I compile
>>- a .log file is created
>>- I open the .log file
>>- I recompile
>>- the .log file is modified
>>- I open the .log file buffer (immediately, so auto-revert is too slow for that)
>>- Emacs asks me if it should reread the .log file
>>- auto-revert reverts the file, but it's too late
>>
>>That's why I would like to disable the revert question for all *.log files.
>>
> 
> Maybe use the variable revert-without-query using a regexp like this :
> ".+\.log$" and set a lower auto-revert-interval (5 by default).


Or perhaps:

;; Warning: Untested!
(defadvice revert-buffer (before yes activate)
   "Always revert buffers visiting *.log files (without querying)."
   (if (and buffer-file-name (string-match "\\.log\\'" buffer-file-name))
       (setq unread-command-events '(?y ?e ?s ?\r))))

-- 
<a href="mailto:&lt;kevin.rodgers&#64;ihs.com&gt;">Kevin Rodgers</a>

  parent reply	other threads:[~2002-12-02 22:26 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-11-29 14:25 Always reread some files arthur.chereau
2002-11-29 15:42 ` Frédéric Bothamy
     [not found] ` <mailman.1038584611.10208.help-gnu-emacs@gnu.org>
2002-12-02 22:26   ` Kevin Rodgers [this message]
     [not found] <mailman.1038580049.4328.help-gnu-emacs@gnu.org>
2002-12-02 22:20 ` Kevin Rodgers
  -- strict thread matches above, loose matches on Subject: below --
2002-11-29 12:48 Victor Kirk
2002-11-29 12:35 arthur.chereau

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=3DEBDE1D.6070209@ihs.com \
    --to=kevinr@ihs.com \
    /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).