From 739593d68742f45e4e35dfc99573c47a5031b646 Mon Sep 17 00:00:00 2001 From: Paul Eggert Date: Sun, 10 Sep 2017 22:21:20 -0700 Subject: [PATCH 3/6] Make gnus-copy-file act like copy-file etc. * etc/NEWS: Mention this. * lisp/gnus/gnus-util.el (gnus-copy-file): Treat the destination as special only if it is a directory name. --- etc/NEWS | 4 ++-- lisp/gnus/gnus-util.el | 3 --- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/etc/NEWS b/etc/NEWS index 4da4c37..fc40a3a 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -1286,8 +1286,8 @@ call like (rename-file C D) that used the old, undocumented behavior can be written as (rename-file C (file-name-as-directory D)), a formulation portable to both older and newer versions of Emacs. Affected functions include add-name-to-file, copy-directory, -copy-file, format-write-file, make-symbolic-link, rename-file, and -write-file. +copy-file, format-write-file, gnus-copy-file, make-symbolic-link, +rename-file, and write-file. * Lisp Changes in Emacs 26.1 diff --git a/lisp/gnus/gnus-util.el b/lisp/gnus/gnus-util.el index b509d8a..93541f0 100644 --- a/lisp/gnus/gnus-util.el +++ b/lisp/gnus/gnus-util.el @@ -594,9 +594,6 @@ gnus-copy-file (read-file-name "Copy file to: " default-directory))) (unless to (setq to (read-file-name "Copy file to: " default-directory))) - (when (file-directory-p to) - (setq to (concat (file-name-as-directory to) - (file-name-nondirectory file)))) (copy-file file to)) (defvar gnus-work-buffer " *gnus work*") -- 2.7.4