]> git.eshelyaron.com Git - emacs.git/commitdiff
Fix recent change in Tramp
authorShuguang Sun <shuguang79@qq.com>
Sat, 29 Jun 2019 10:18:59 +0000 (12:18 +0200)
committerMichael Albinus <michael.albinus@gmx.de>
Sat, 29 Jun 2019 10:18:59 +0000 (12:18 +0200)
* lisp/net/tramp-adb.el:
* lisp/net/tramp-archive.el:
* lisp/net/tramp-integration.el: Remove superfluous `progn' in
`with-eval-after-load'.

lisp/net/tramp-adb.el
lisp/net/tramp-archive.el
lisp/net/tramp-integration.el

index c8b9e7ae09ca4626f69001df3dddd4a5de6c20a3..186b67c6e934239f2bca4307c46dcbf621d925da 100644 (file)
@@ -1299,15 +1299,14 @@ connection if a previous connection has died for some reason."
 ;; `connection-local-set-profile-variables' and
 ;; `connection-local-set-profiles' exists since Emacs 26.1.
 (with-eval-after-load 'shell
-  (progn
-    (tramp-compat-funcall
-     'connection-local-set-profile-variables
-     'tramp-adb-connection-local-default-profile
-     tramp-adb-connection-local-default-profile)
-    (tramp-compat-funcall
-     'connection-local-set-profiles
-     `(:application tramp :protocol ,tramp-adb-method)
-     'tramp-adb-connection-local-default-profile)))
+  (tramp-compat-funcall
+   'connection-local-set-profile-variables
+   'tramp-adb-connection-local-default-profile
+   tramp-adb-connection-local-default-profile)
+  (tramp-compat-funcall
+   'connection-local-set-profiles
+   `(:application tramp :protocol ,tramp-adb-method)
+   'tramp-adb-connection-local-default-profile))
 
 (add-hook 'tramp-unload-hook
          (lambda ()
index b329d4a1b117d1c40518fb7ae34bcd2af5a8a117..82fd327770b20e92c9a8b40ccccd404e699fbace 100644 (file)
@@ -373,13 +373,12 @@ pass to the OPERATION."
 (when url-handler-mode (tramp-register-file-name-handlers))
 
 (with-eval-after-load 'url-handler
-  (progn
-    (add-hook 'url-handler-mode-hook #'tramp-register-file-name-handlers)
-    (add-hook
-     'tramp-archive-unload-hook
-     (lambda ()
-       (remove-hook
-       'url-handler-mode-hook #'tramp-register-file-name-handlers)))))
+  (add-hook 'url-handler-mode-hook #'tramp-register-file-name-handlers)
+  (add-hook
+   'tramp-archive-unload-hook
+   (lambda ()
+     (remove-hook
+      'url-handler-mode-hook #'tramp-register-file-name-handlers))))
 
 \f
 ;; File name conversions.
index 5960871ca7adeb49cd836bf75ff4e660a04fb974..0c706da1ca184cb134f0782c0ddd461534aeb8eb 100644 (file)
@@ -124,17 +124,16 @@ been set up by `rfn-eshadow-setup-minibuffer'."
         #'identity (butlast (tramp-compat-exec-path)) path-separator)))
 
 (with-eval-after-load 'esh-util
-  (progn
-    (add-hook 'eshell-mode-hook
-             #'tramp-eshell-directory-change)
-    (add-hook 'eshell-directory-change-hook
-             #'tramp-eshell-directory-change)
-    (add-hook 'tramp-integration-unload-hook
-             (lambda ()
-               (remove-hook 'eshell-mode-hook
-                            #'tramp-eshell-directory-change)
-               (remove-hook 'eshell-directory-change-hook
-                            #'tramp-eshell-directory-change)))))
+  (add-hook 'eshell-mode-hook
+           #'tramp-eshell-directory-change)
+  (add-hook 'eshell-directory-change-hook
+           #'tramp-eshell-directory-change)
+  (add-hook 'tramp-integration-unload-hook
+           (lambda ()
+             (remove-hook 'eshell-mode-hook
+                          #'tramp-eshell-directory-change)
+             (remove-hook 'eshell-directory-change-hook
+                          #'tramp-eshell-directory-change))))
 
 ;;; Integration of recentf.el:
 
@@ -159,17 +158,16 @@ NAME must be equal to `tramp-current-connection'."
       (recentf-cleanup))))
 
 (with-eval-after-load 'recentf
-  (progn
-    (add-hook 'tramp-cleanup-connection-hook
-             #'tramp-recentf-cleanup)
-    (add-hook 'tramp-cleanup-all-connections-hook
-             #'tramp-recentf-cleanup-all)
-    (add-hook 'tramp-integration-unload-hook
-             (lambda ()
-               (remove-hook 'tramp-cleanup-connection-hook
-                            #'tramp-recentf-cleanup)
-               (remove-hook 'tramp-cleanup-all-connections-hook
-                            #'tramp-recentf-cleanup-all)))))
+  (add-hook 'tramp-cleanup-connection-hook
+           #'tramp-recentf-cleanup)
+  (add-hook 'tramp-cleanup-all-connections-hook
+           #'tramp-recentf-cleanup-all)
+  (add-hook 'tramp-integration-unload-hook
+           (lambda ()
+             (remove-hook 'tramp-cleanup-connection-hook
+                          #'tramp-recentf-cleanup)
+             (remove-hook 'tramp-cleanup-all-connections-hook
+                          #'tramp-recentf-cleanup-all))))
 
 ;;; Default connection-local variables for Tramp:
 
@@ -181,15 +179,14 @@ NAME must be equal to `tramp-current-connection'."
 ;; `connection-local-set-profile-variables' and
 ;; `connection-local-set-profiles' exists since Emacs 26.1.
 (with-eval-after-load 'shell
-  (progn
-    (tramp-compat-funcall
-     'connection-local-set-profile-variables
-     'tramp-connection-local-default-profile
-     tramp-connection-local-default-profile)
-    (tramp-compat-funcall
-     'connection-local-set-profiles
-     `(:application tramp)
-     'tramp-connection-local-default-profile)))
+  (tramp-compat-funcall
+   'connection-local-set-profile-variables
+   'tramp-connection-local-default-profile
+   tramp-connection-local-default-profile)
+  (tramp-compat-funcall
+   'connection-local-set-profiles
+   `(:application tramp)
+   'tramp-connection-local-default-profile))
 
 (add-hook 'tramp-unload-hook
          (lambda () (unload-feature 'tramp-integration 'force)))