[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#18751: 25.0.50; Unable to copy hidden (dot) files from remote shared
From: |
Michael Albinus |
Subject: |
bug#18751: 25.0.50; Unable to copy hidden (dot) files from remote shared server (Linux) to local machine (OSX). |
Date: |
Mon, 03 Nov 2014 15:42:44 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux) |
Michael Albinus <michael.albinus@gmx.de> writes:
Hi Keith,
>> Evaluating `(tramp-do-copy-or-rename-file 'copy filename new-filename
>> t t t)` is working well on all individual files, including
>> `.www.my.cnf`.
>>
>> `dired-do-copy` is working well on all individual files, and on
>> multiple marked files.
>>
>> However, `dired-do-copy` cannot handle any remote directory on the
>> remote server with files inside it. Placing the cursor on any
>> directory on the remote server and issuing the command `dired-do-copy`
>> results in only that folder being copied to the local machine, but
>> noting inside it gets copied over.
>
> Thanks for this precision. Now I'm able to reproduce the problem, even
> with older Emacs versions.
Finally, I could fix it. I've committed the following patch to the
emacs-24 branch (shall appear in the trunk in a few days):
--8<---------------cut here---------------start------------->8---
*** /home/albinus/src/emacs-24/lisp/net/tramp-sh.el.~117655~ 2014-11-03
15:37:00.228854359 +0100
--- /home/albinus/src/emacs-24/lisp/net/tramp-sh.el 2014-11-03
15:22:10.311994500 +0100
***************
*** 2061,2071 ****
KEEP-DATE is non-nil if NEWNAME should have the same timestamp as FILENAME."
(with-temp-buffer
;; We must disable multibyte, because binary data shall not be
! ;; converted.
(set-buffer-multibyte nil)
(let ((coding-system-for-read 'binary)
! (jka-compr-inhibit t))
! (insert-file-contents-literally filename))
;; We don't want the target file to be compressed, so we let-bind
;; `jka-compr-inhibit' to t.
(let ((coding-system-for-write 'binary)
--- 2061,2075 ----
KEEP-DATE is non-nil if NEWNAME should have the same timestamp as FILENAME."
(with-temp-buffer
;; We must disable multibyte, because binary data shall not be
! ;; converted. `insert-file-contents-literally' does not support
! ;; file name handlers for GNU Emacs; we must create a local copy
! ;; therefore.
(set-buffer-multibyte nil)
(let ((coding-system-for-read 'binary)
! (jka-compr-inhibit t)
! (tmpfile (file-local-copy filename)))
! (insert-file-contents-literally (or tmpfile filename))
! (when tmpfile (delete-file tmpfile)))
;; We don't want the target file to be compressed, so we let-bind
;; `jka-compr-inhibit' to t.
(let ((coding-system-for-write 'binary)
--8<---------------cut here---------------end--------------->8---
Could you, please, check it?
Best regards, Michael.
- bug#18751: 25.0.50; Unable to copy hidden (dot) files from remote shared server (Linux) to local machine (OSX).,
Michael Albinus <=