[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/tramp ee53c26a61: Tramp ELPA version 2.6.1.1 released
From: |
ELPA Syncer |
Subject: |
[elpa] externals/tramp ee53c26a61: Tramp ELPA version 2.6.1.1 released |
Date: |
Sun, 30 Jul 2023 03:58:35 -0400 (EDT) |
branch: externals/tramp
commit ee53c26a61540d3ddf01af95d6508e9493377106
Author: Michael Albinus <michael.albinus@gmx.de>
Commit: Michael Albinus <michael.albinus@gmx.de>
Tramp ELPA version 2.6.1.1 released
---
README | 4 ++--
test/tramp-tests.el | 5 ++++-
texi/tramp.texi | 4 +++-
texi/trampver.texi | 2 +-
tramp-gvfs.el | 2 ++
tramp-rclone.el | 24 ++++++++++++++++++++----
tramp-sh.el | 8 +++++++-
tramp.el | 13 +++++++------
trampver.el | 6 +++---
9 files changed, 49 insertions(+), 19 deletions(-)
diff --git a/README b/README
index a27e105fdc..47bb5da084 100644
--- a/README
+++ b/README
@@ -22,11 +22,11 @@ installed with, you must recompile the package:
• Remove all byte-compiled Tramp files
- $ rm -f ~/.emacs.d/elpa/tramp-2.6.1/tramp*.elc
+ $ rm -f ~/.emacs.d/elpa/tramp-2.6.1.1/tramp*.elc
• Start Emacs with Tramp’s source files
- $ emacs -L ~/.emacs.d/elpa/tramp-2.6.1 -l tramp
+ $ emacs -L ~/.emacs.d/elpa/tramp-2.6.1.1 -l tramp
This should not give you the error.
diff --git a/test/tramp-tests.el b/test/tramp-tests.el
index 6d06da261a..00e368abe4 100644
--- a/test/tramp-tests.el
+++ b/test/tramp-tests.el
@@ -6076,7 +6076,9 @@ INPUT, if non-nil, is a string sent to the process."
;; Unset the variable.
(let ((tramp-remote-process-environment
(cons (concat envvar "=foo") tramp-remote-process-environment)))
- ;; Set the initial value, we want to unset below.
+ ;; Refill the cache; we don't want to run into timeouts.
+ (file-truename default-directory)
+ ;; Check the initial value, we want to unset below.
(should
(string-match-p
"foo"
@@ -8014,6 +8016,7 @@ Since it unloads Tramp, it shall be the last test to run."
(and (functionp x) (null (autoloadp (symbol-function x))))
(macrop x))
(string-prefix-p "tramp" (symbol-name x))
+ (string-match-p (rx bol "with" (| "tramp" "parsed")) (symbol-name x))
;; `tramp-completion-mode' is autoloaded in Emacs < 28.1.
(not (eq 'tramp-completion-mode x))
;; `tramp-register-archive-file-name-handler' is autoloaded
diff --git a/texi/tramp.texi b/texi/tramp.texi
index 72fcbb8021..b523fe21bf 100644
--- a/texi/tramp.texi
+++ b/texi/tramp.texi
@@ -289,9 +289,11 @@ accumulated in the buffer, then decodes that output to
produce the
file's contents.
For external transfers, @value{tramp} sends a command as follows:
+
@example
-$ rcp user@@host:/path/to/remote/file /tmp/tramp.4711
+$ scp user@@host:/path/to/remote/file /tmp/tramp.4711
@end example
+
@value{tramp} reads the local temporary file @file{/tmp/tramp.4711}
into a buffer, and then deletes the temporary file.
diff --git a/texi/trampver.texi b/texi/trampver.texi
index 3c2553c8db..e321759f1a 100644
--- a/texi/trampver.texi
+++ b/texi/trampver.texi
@@ -7,7 +7,7 @@
@c In the Tramp GIT, the version number and the bug report address
@c are auto-frobbed from configure.ac.
-@set trampver 2.6.1
+@set trampver 2.6.1.1
@set trampurl https://www.gnu.org/software/tramp/
@set tramp-bug-report-address tramp-devel@@gnu.org
@set emacsver 26.1
diff --git a/tramp-gvfs.el b/tramp-gvfs.el
index 8b7e492358..4634204288 100644
--- a/tramp-gvfs.el
+++ b/tramp-gvfs.el
@@ -1034,6 +1034,8 @@ file names."
(when (and (file-directory-p newname)
(not (directory-name-p newname)))
(tramp-error v 'file-error "File is a directory %s" newname))
+ (when (file-regular-p newname)
+ (delete-file newname))
(cond
;; We cannot rename volatile files, as used by Google-drive.
diff --git a/tramp-rclone.el b/tramp-rclone.el
index 6a1446bd2b..70bbf7e019 100644
--- a/tramp-rclone.el
+++ b/tramp-rclone.el
@@ -224,6 +224,7 @@ file names."
(let ((t1 (tramp-tramp-file-p filename))
(t2 (tramp-tramp-file-p newname))
+ (equal-remote (tramp-equal-remote filename newname))
(rclone-operation (if (eq op 'copy) "copyto" "moveto"))
(msg-operation (if (eq op 'copy) "Copying" "Renaming")))
@@ -234,8 +235,12 @@ file names."
(when (and (file-directory-p newname)
(not (directory-name-p newname)))
(tramp-error v 'file-error "File is a directory %s" newname))
+ (when (file-regular-p newname)
+ (delete-file newname))
- (if (or (and t1 (not (tramp-rclone-file-name-p filename)))
+ (if (or (and equal-remote
+ (tramp-get-connection-property v "direct-copy-failed"))
+ (and t1 (not (tramp-rclone-file-name-p filename)))
(and t2 (not (tramp-rclone-file-name-p newname))))
;; We cannot copy or rename directly.
@@ -255,9 +260,20 @@ file names."
v rclone-operation
(tramp-rclone-remote-file-name filename)
(tramp-rclone-remote-file-name newname)))
- (tramp-error
- v 'file-error
- "Error %s `%s' `%s'" msg-operation filename newname)))
+ (if (or (not equal-remote)
+ (and equal-remote
+ (tramp-get-connection-property
+ v "direct-copy-failed")))
+ (tramp-error
+ v 'file-error
+ "Error %s `%s' `%s'" msg-operation filename newname)
+
+ ;; Some WebDAV server, like the one from QNAP, do
+ ;; not support direct copy/move. Try a fallback.
+ (tramp-set-connection-property v "direct-copy-failed" t)
+ (tramp-rclone-do-copy-or-rename-file
+ op filename newname ok-if-already-exists keep-date
+ preserve-uid-gid preserve-extended-attributes))))
(when (and t1 (eq op 'rename))
(while (file-exists-p filename)
diff --git a/tramp-sh.el b/tramp-sh.el
index 7915ea9a8a..9895af9250 100644
--- a/tramp-sh.el
+++ b/tramp-sh.el
@@ -2309,6 +2309,11 @@ the uid and gid from FILENAME."
;; Save exit.
(ignore-errors (delete-file tmpfile)))))))))
+ ;; When newname did exist, we have wrong cached values.
+ (when t2
+ (with-parsed-tramp-file-name newname v2
+ (tramp-flush-file-properties v2 v2-localname)))
+
;; Set the time and mode. Mask possible errors.
(ignore-errors
(when keep-date
@@ -2807,7 +2812,8 @@ the result will be a local, non-Tramp, file name."
;; there could be the false positive "/:".
(if (or (and (eq system-type 'windows-nt)
(string-match-p
- (tramp-compat-rx bol (| (: alpha ":") (: (literal null-device)
eol)))
+ (tramp-compat-rx
+ bol (| (: alpha ":") (: (literal (or null-device "")) eol)))
name))
(and (not (tramp-tramp-file-p name))
(not (tramp-tramp-file-p dir))))
diff --git a/tramp.el b/tramp.el
index 649b8578e4..0b530ecc81 100644
--- a/tramp.el
+++ b/tramp.el
@@ -1980,11 +1980,10 @@ version, the function does nothing."
"Return contents of BUFFER.
If BUFFER is not a buffer or a buffer name, return the contents
of `current-buffer'."
- (or (let ((buf (or buffer (current-buffer))))
- (when (bufferp buf)
- (with-current-buffer (or buffer (current-buffer))
- (substring-no-properties (buffer-string)))))
- ""))
+ (with-current-buffer
+ (if (or (bufferp buffer) (and (stringp buffer) (get-buffer buffer)))
+ buffer (current-buffer))
+ (substring-no-properties (buffer-string))))
(defun tramp-debug-buffer-name (vec)
"A name for the debug buffer for VEC."
@@ -3863,7 +3862,7 @@ Let-bind it when necessary.")
(defun tramp-handle-access-file (filename string)
"Like `access-file' for Tramp files."
(setq filename (file-truename filename))
- (with-parsed-tramp-file-name filename v
+ (with-parsed-tramp-file-name filename nil
(if (file-exists-p filename)
(unless
(funcall
@@ -6916,5 +6915,7 @@ If VEC is `tramp-null-hop', return local null device."
;; "/ssh:user1@host:~user2".
;;
;; * Implement file name abbreviation for user and host names.
+;;
+;; * Implement user and host name completion for multi-hops.
;;; tramp.el ends here
diff --git a/trampver.el b/trampver.el
index 672a9aa200..16c1ecb025 100644
--- a/trampver.el
+++ b/trampver.el
@@ -7,7 +7,7 @@
;; Maintainer: Michael Albinus <michael.albinus@gmx.de>
;; Keywords: comm, processes
;; Package: tramp
-;; Version: 2.6.1
+;; Version: 2.6.1.1
;; Package-Requires: ((emacs "26.1"))
;; Package-Type: multi
;; URL: https://www.gnu.org/software/tramp/
@@ -40,7 +40,7 @@
;; ./configure" to change them.
;;;###tramp-autoload
-(defconst tramp-version "2.6.1"
+(defconst tramp-version "2.6.1.1"
"This version of Tramp.")
;;;###tramp-autoload
@@ -78,7 +78,7 @@
;; Check for Emacs version.
(let ((x (if (not (string-version-lessp emacs-version "26.1"))
"ok"
- (format "Tramp 2.6.1 is not fit for %s"
+ (format "Tramp 2.6.1.1 is not fit for %s"
(replace-regexp-in-string "\n" "" (emacs-version))))))
(unless (string-equal "ok" x) (error "%s" x)))
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [elpa] externals/tramp ee53c26a61: Tramp ELPA version 2.6.1.1 released,
ELPA Syncer <=