From: Sean Whitton Date: Tue, 24 Sep 2024 15:17:17 +0000 (+0100) Subject: diff-apply-buffer: Improve failure message X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=a48e9c0c7bc2cbfc3463fd07ba8c9cd3f33ae807;p=emacs.git diff-apply-buffer: Improve failure message * lisp/vc/diff-mode.el (diff-apply-buffer): Say "hunk", not "hunks", when there was only one failed hunk. (cherry picked from commit ce601de1cafa65d6e6f5ba52e9c794873d164fbd) --- diff --git a/lisp/vc/diff-mode.el b/lisp/vc/diff-mode.el index f1193885d6e..49159731e30 100644 --- a/lisp/vc/diff-mode.el +++ b/lisp/vc/diff-mode.el @@ -2092,7 +2092,8 @@ When applying all hunks was successful, then save the changed buffers." (save-buffer))) (message "Saved %d buffers" (length buffer-edits))) (t - (message "%d hunks failed; no buffers changed" failures))))) + (message "%d %s failed; no buffers changed" + failures (if (> failures 1) "hunks" "hunk")))))) (defalias 'diff-mouse-goto-source #'diff-goto-source)