Source

dired / dired-diff.el

Diff from to

dired-diff.el

 ;;
 ;; File:           dired-diff.el
 ;; RCS:
-;; Dired Version:  #Revision: 7.9 $
+;; Dired Version:  #Revision: 7.10 $
 ;; Description:    Support for diff and related commands.
 ;; Author:         Sandy Rutherford <sandy@ibm550.sissa.it>
 ;; Created:        Fri Jun 24 08:50:20 1994 by sandy on ibm550
 
 (provide 'dired-diff)
 (require 'dired)
+(require 'diff-mode)
 
 (defvar emerge-last-dir-input)
 (defvar emerge-last-dir-output)
 
 (defun dired-diff-read-switches (switchprompt)
   ;; Read and return a list of switches
-  (or (boundp 'diff-switches)
-      (require 'diff)) ; Make sure that `diff-switches' is defined.
   (let* ((default (if (listp diff-switches)
 		      (mapconcat 'identity diff-switches " ")
 		    diff-switches))
 	      start (match-end 0)))
       (nreverse result))))
 
+;;;###autoload
 (defun dired-diff (file &optional switches)
   "Compare file at point with file FILE using `diff'.
 FILE defaults to the file at the mark.
       (diff file (dired-get-filename) switches)
     (diff file (dired-get-filename))))
 
+;;;###autoload
 (defun dired-backup-diff (&optional switches)
   "Diff this file with its backup file or vice versa.
 Uses the latest backup, if there are several numerical backups.
       (diff-backup (dired-get-filename) switches)
     (diff-backup (dired-get-filename))))
 
+;;;###autoload
 (defun dired-emerge (arg file out-file)
   "Merge file at point with FILE using `emerge'.
 FILE defaults to the file at the mark."
 			       (dired-abbreviate-file-name file) file)))))
   (emerge-files arg file (dired-get-filename) out-file))
 
+;;;###autoload
 (defun dired-emerge-with-ancestor (arg file ancestor file-out)
   "Merge file at point with FILE, using a common ANCESTOR file.
 FILE defaults to the file at the mark."
   (emerge-files-with-ancestor arg file (dired-get-filename)
 			      ancestor file-out))
 
+;;;###autoload
 (defun dired-ediff (file)
   "Ediff file at point with FILE.
 FILE defaults to the file at the mark."
   (interactive (list (dired-diff-read-file-name "Ediff")))
   (ediff-files file (dired-get-filename)))
 
+;;;###autoload
 (defun dired-epatch (file)
   "Patch file at point using `epatch'."
   (interactive