Variable: inhibit-auto-revert-buffers

inhibit-auto-revert-buffers is a variable defined in autorevert.el.gz.

Value

nil

Documentation

A list of buffers with suppressed auto-revert.

View in manual

Probably introduced at or before Emacs version 31.1.

Source Code

;; Defined in /usr/src/emacs/lisp/autorevert.el.gz
;;;###autoload
(progn
  (defvar inhibit-auto-revert-buffers nil
    "A list of buffers with suppressed auto-revert.")

  (defmacro inhibit-auto-revert (&rest body)
    "Deactivate auto-reverting of current buffer temporarily.
Run BODY."
    (declare (indent 0) (debug (body)))
    (let ((buf (make-symbol "buf")))
      `(progn
         ;; Cleanup.
         (dolist (,buf inhibit-auto-revert-buffers)
           (unless (buffer-live-p ,buf)
             (setq inhibit-auto-revert-buffers
                   (delq ,buf inhibit-auto-revert-buffers))))
         (let ((,buf
                (and (not (memq (current-buffer) inhibit-auto-revert-buffers))
                     (current-buffer))))
           (unwind-protect
               (progn
                 (when ,buf (add-to-list 'inhibit-auto-revert-buffers ,buf))
                 ,@body)
             (when ,buf
               (setq inhibit-auto-revert-buffers
                     (delq ,buf inhibit-auto-revert-buffers)))))))))