Variable: multi-file-diff-unsaved

multi-file-diff-unsaved is a customizable variable defined in misearch.el.gz.

Value

save-buffers

Documentation

What to do with unsaved edits when showing multi-file replacements as diffs.

If the value is save-buffers, save unsaved buffers before creating diff. If the value is use-file, use text from the file even when the file-visiting buffer is modified. If the value is use-modified-buffer, use text from the file-visiting modified buffer to be able to use unsaved changes.

This variable was added, or its default value changed, in Emacs 30.1.

Source Code

;; Defined in /usr/src/emacs/lisp/misearch.el.gz
;;; Global multi-file replacements as diff

(defcustom multi-file-diff-unsaved 'save-buffers
  "What to do with unsaved edits when showing multi-file replacements as diffs.
If the value is `save-buffers', save unsaved buffers before creating diff.
If the value is `use-file', use text from the file even when the
file-visiting buffer is modified.
If the value is `use-modified-buffer', use text from the file-visiting
modified buffer to be able to use unsaved changes."
  :type '(choice
          (const :tag "Save buffers" save-buffers)
          (const :tag "Use file" use-file)
          (const :tag "Use modified buffer" use-modified-buffer))
  :version "30.1")