1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2025-12-15 10:30:25 -08:00

Implement "/media::" default host name in Tramp

* doc/misc/tramp.texi (GVFS-based methods): Describe default
/media:: file name.

* lisp/net/tramp-cache.el (tramp-get-file-property)
(tramp-set-file-property): Check, whether
`tramp-cache-{g,s}et-count-*' objects are numbers.

* lisp/net/tramp-gvfs.el (top): Don't set global default for
"media" in `tramp-default-host-alist'.
(tramp-gvfs-handler-volumeadded-volumeremoved): New defun.
(top): Register "org.gtk.Private.RemoteVolumeMonitor.VolumeAdded"
and "org.gtk.Private.RemoteVolumeMonitor.VolumeRemoved" signals.
(tramp-get-media-devices): Set defaults for "media" in
`tramp-default-host-alist'.
This commit is contained in:
Michael Albinus 2020-01-23 14:09:35 +01:00
parent 72011f23c3
commit 8fbc2fd492
3 changed files with 51 additions and 17 deletions

View file

@ -141,7 +141,7 @@ Returns DEFAULT if not set."
(tramp-message key 8 "%s %s %s" file property value)
(when (>= tramp-verbose 10)
(let* ((var (intern (concat "tramp-cache-get-count-" property)))
(val (or (bound-and-true-p var)
(val (or (numberp (bound-and-true-p var))
(progn
(add-hook 'tramp-cache-unload-hook
(lambda () (makunbound var)))
@ -165,7 +165,7 @@ Returns VALUE."
(tramp-message key 8 "%s %s %s" file property value)
(when (>= tramp-verbose 10)
(let* ((var (intern (concat "tramp-cache-set-count-" property)))
(val (or (bound-and-true-p var)
(val (or (numberp (bound-and-true-p var))
(progn
(add-hook 'tramp-cache-unload-hook
(lambda () (makunbound var)))