Fix Tramp shortdoc integration

* lisp/net/tramp-integration.el (tramp-syntax): Declare.
(shortdoc): Check, that Tramp has `default' syntax.
This commit is contained in:
Michael Albinus 2024-09-25 19:43:07 +02:00
parent 759b18a33c
commit d63bff4d88

View 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':
@ -277,7 +278,8 @@ NAME must be equal to `tramp-current-connection'."
(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)