]> git.eshelyaron.com Git - emacs.git/commitdiff
Fix Tramp shortdoc integration
authorMichael Albinus <michael.albinus@gmx.de>
Wed, 25 Sep 2024 17:43:07 +0000 (19:43 +0200)
committerEshel Yaron <me@eshelyaron.com>
Mon, 30 Sep 2024 19:40:00 +0000 (21:40 +0200)
* lisp/net/tramp-integration.el (tramp-syntax): Declare.
(shortdoc): Check, that Tramp has `default' syntax.

(cherry picked from commit d63bff4d88f32c31fa16f313f11ad2ab7485d4f9)

lisp/net/tramp-integration.el

index af48714980fd8e518cf9b5fb26c506b4e9e8ab24..0a99711d2223f7c4a053da5cea2514e6c02a11c3 100644 (file)
@@ -54,6 +54,7 @@
 (defvar shortdoc--groups)
 (defvar tramp-current-connection)
 (defvar tramp-postfix-host-format)
+(defvar tramp-syntax)
 (defvar tramp-use-connection-share)
 
 ;;; Fontification of `read-file-name':
@@ -304,7 +305,8 @@ It's value must be a Tramp user option, indexed in the Tramp manual via
 (tramp--with-startup
  (with-eval-after-load 'shortdoc
    ;; Some packages deactivate Tramp.  They don't deserve a shortdoc entry then.
-   (when (file-remote-p "/ssh:user@host:/tmp/foo")
+   (when (and (file-remote-p "/ssh:user@host:/tmp/foo")
+              (eq tramp-syntax 'default))
      (dolist (elem `((file-remote-p
                      :eval (file-remote-p "/ssh:user@host:/tmp/foo")
                      :eval (file-remote-p "/ssh:user@host:/tmp/foo" 'method)