Offensichtlich url-copy-file
ist die beste Option, aber den abenteuerlichen Emacs Hacker würde ich so etwas wie dies vorschlägt:
(require 'url)
(defun download-file (&optional url download-dir download-name)
(interactive)
(let ((url (or url
(read-string "Enter download URL: "))))
(let ((download-buffer (url-retrieve-synchronously url)))
(save-excursion
(set-buffer download-buffer)
;; we may have to trim the http response
(goto-char (point-min))
(re-search-forward "^$" nil 'move)
(forward-char)
(delete-region (point-min) (point))
(write-file (concat (or download-dir
"~/downloads/")
(or download-name
(car (last (split-string url "/" t))))))))))
Wenn Sie nur die Remote-Datei in einen Emacs-Puffer bekommen wollen, ist 'browse-url-emacs' praktisch. – phils