emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] externals/ssh-deploy cb4c6ff 020/133: Using (expand-file-name) in


From: Stefan Monnier
Subject: [elpa] externals/ssh-deploy cb4c6ff 020/133: Using (expand-file-name) instead of (concat)
Date: Sat, 27 Mar 2021 14:48:35 -0400 (EDT)

branch: externals/ssh-deploy
commit cb4c6ff7d88db8e6c1f7dd1305617ddb07f419ee
Author: Christian Johansson <christian@cvj.se>
Commit: Christian Johansson <christian@cvj.se>

    Using (expand-file-name) instead of (concat)
---
 ssh-deploy-diff-mode.el | 38 +++++++++++++++++++-------------------
 1 file changed, 19 insertions(+), 19 deletions(-)

diff --git a/ssh-deploy-diff-mode.el b/ssh-deploy-diff-mode.el
index e6d3f99..c921aba 100644
--- a/ssh-deploy-diff-mode.el
+++ b/ssh-deploy-diff-mode.el
@@ -162,7 +162,7 @@
            (fboundp 'ssh-deploy-diff-directories))
       (let ((root-local (nth 2 parts))
             (root-remote (nth 3 parts))
-            (async (cond ((boundp 'ssh-deploy-async) ssh-deploy-async)(t nil)))
+            (async (cond ((boundp 'ssh-deploy-async) ssh-deploy-async)(t 0)))
             (exclude-list (cond ((boundp 'ssh-deploy-exclude-list) 
ssh-deploy-exclude-list)(t nil))))
         (progn
           (kill-this-buffer)
@@ -174,10 +174,10 @@
   (let* ((file-name (nth 0 parts))
          (root-local (file-truename (nth 2 parts)))
          (root-remote (nth 3 parts))
-         (path-local (file-truename (concat root-local file-name)))
-         (path-remote (concat root-remote file-name))
+         (path-local (file-truename (expand-file-name file-name root-local)))
+         (path-remote (expand-file-name file-name root-remote))
          (section (nth 1 parts))
-         (async (cond ((boundp 'ssh-deploy-async) ssh-deploy-async)(t nil)))
+         (async (cond ((boundp 'ssh-deploy-async) ssh-deploy-async)(t 0)))
          (revision-folder (cond ((boundp 'ssh-deploy-revision-folder) 
ssh-deploy-revision-folder)(t nil))))
     (if (and (fboundp 'ssh-deploy-download)
              (fboundp 'ssh-deploy-upload))
@@ -195,14 +195,14 @@
          (file-name (nth 0 parts))
          (root-local (file-truename (nth 2 parts)))
          (root-remote (nth 3 parts))
-         (path-local (file-truename (concat root-local file-name)))
-         (path-remote (concat root-remote file-name))
-         (async (cond ((boundp 'ssh-deploy-async) ssh-deploy-async)(t nil)))
+         (path-local (file-truename (expand-file-name file-name root-local)))
+         (path-remote (expand-file-name file-name root-remote))
+         (async (cond ((boundp 'ssh-deploy-async) ssh-deploy-async)(t 0)))
          (revision-folder (cond ((boundp 'ssh-deploy-revision-folder) 
ssh-deploy-revision-folder)(t nil))))
     (if (fboundp 'ssh-deploy-upload)
         (cond ((or (= section ssh-deploy-diff-mode--section-only-in-a)
                    (= section ssh-deploy-diff-mode--section-in-both))
-               (ssh-deploy-upload path-local path-remote t async 
revision-folder))
+               (ssh-deploy-upload path-local path-remote 1 async 
revision-folder))
               (t "Copy A is not available in this section"))
       (display-warning 'ssh-deploy "Function ssh-deploy-upload is missing" 
:warning))))
 
@@ -213,9 +213,9 @@
          (file-name (nth 0 parts))
          (root-local (file-truename (nth 2 parts)))
          (root-remote (nth 3 parts))
-         (path-local (file-truename (concat root-local file-name)))
-         (path-remote (concat root-remote file-name))
-         (async (cond ((boundp 'ssh-deploy-async) ssh-deploy-async)(t nil)))
+         (path-local (file-truename (expand-file-name file-name root-local)))
+         (path-remote (expand-file-name file-name root-remote))
+         (async (cond ((boundp 'ssh-deploy-async) ssh-deploy-async)(t 0)))
          (revision-folder (cond ((boundp 'ssh-deploy-revision-folder) 
ssh-deploy-revision-folder)(t nil))))
     (if (fboundp 'ssh-deploy-download)
         (cond ((or (= section ssh-deploy-diff-mode--section-only-in-b)
@@ -231,10 +231,10 @@
          (file-name (nth 0 parts))
          (root-local (nth 2 parts))
          (root-remote (nth 3 parts))
-         (path-local (file-truename (concat root-local file-name)))
-         (path-remote (file-truename (concat root-remote file-name)))
-         (async (cond ((boundp 'ssh-deploy-async) ssh-deploy-async)(t nil)))
-         (debug (cond ((boundp 'ssh-deploy-debug) ssh-deploy-debug)(t nil)))
+         (path-local (file-truename (expand-file-name file-name root-local)))
+         (path-remote (expand-file-name file-name root-remote))
+         (async (cond ((boundp 'ssh-deploy-async) ssh-deploy-async)(t 0)))
+         (debug (cond ((boundp 'ssh-deploy-debug) ssh-deploy-debug)(t 0)))
          (exclude-list (cond ((boundp 'ssh-deploy-exclude-list) 
ssh-deploy-exclude-list)(t nil)))
          (revision-folder (cond ((boundp 'ssh-deploy-revision-folder) 
ssh-deploy-revision-folder)(t nil))))
     (if (and (fboundp 'ssh-deploy-delete)
@@ -258,8 +258,8 @@
             (let* ((file-name (nth 0 parts))
                    (root-local (file-truename (nth 2 parts)))
                    (root-remote (nth 3 parts))
-                   (path-local (file-truename (concat root-local file-name)))
-                   (path-remote (concat root-remote file-name)))
+                   (path-local (file-truename (expand-file-name file-name 
root-local)))
+                   (path-remote (expand-file-name file-name root-remote)))
               (ssh-deploy-diff-files path-local path-remote)))
       (display-warning 'ssh-deploy "Function ssh-deploy-diff-files is missing" 
:warning))
     (message "File must exists in both roots to perform a difference 
action.")))
@@ -271,8 +271,8 @@
          (file-name (nth 0 parts))
          (root-local (file-truename (nth 2 parts)))
          (root-remote (nth 3 parts))
-         (path-local (file-truename (concat root-local file-name)))
-         (path-remote (concat root-remote file-name)))
+         (path-local (file-truename (expand-file-name file-name root-local)))
+         (path-remote (expand-file-name file-name root-remote)))
     (cond ((= section ssh-deploy-diff-mode--section-only-in-a)
            (progn
              (message "Opening file '%s'" path-local)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]