Function: ediff-buffers

ediff-buffers is an autoloaded, interactive and byte-compiled function defined in ediff.el.gz.

Signature

(ediff-buffers BUFFER-A BUFFER-B &optional STARTUP-HOOKS JOB-NAME)

Documentation

Run Ediff on a pair of buffers, BUFFER-A and BUFFER-B.

STARTUP-HOOKS is a list of functions that Emacs calls without arguments after setting up the Ediff buffers. JOB-NAME is a symbol describing the Ediff job type; it defaults to ediff-buffers, but can also be one of ediff-merge-files-with-ancestor, ediff-last-dir-ancestor, ediff-last-dir-C, ediff-buffers3, ediff-merge-buffers, or ediff-merge-buffers-with-ancestor.

Key Bindings

Aliases

ebuffers

Source Code

;; Defined in /usr/src/emacs/lisp/vc/ediff.el.gz
;;;###autoload
(defun ediff-buffers (buffer-A buffer-B &optional startup-hooks job-name)
  "Run Ediff on a pair of buffers, BUFFER-A and BUFFER-B.
STARTUP-HOOKS is a list of functions that Emacs calls without
arguments after setting up the Ediff buffers.  JOB-NAME is a
symbol describing the Ediff job type; it defaults to
`ediff-buffers', but can also be one of
`ediff-merge-files-with-ancestor', `ediff-last-dir-ancestor',
`ediff-last-dir-C', `ediff-buffers3', `ediff-merge-buffers', or
`ediff-merge-buffers-with-ancestor'."
  (interactive
   (let (bf)
     (list (setq bf (read-buffer "Buffer A to compare: "
				 (ediff-other-buffer "") t))
	   (read-buffer "Buffer B to compare: "
			(progn
			  ;; realign buffers so that two visible bufs will be
			  ;; at the top
			  (save-window-excursion (other-window 1))
			  (ediff-other-buffer bf))
			t))))
  (or job-name (setq job-name 'ediff-buffers))
  (ediff-buffers-internal buffer-A buffer-B nil startup-hooks job-name))