Function: dired-rsync--extract-host-from-tramp
dired-rsync--extract-host-from-tramp is a natively compiled function
defined in dired-rsync.el.
Signature
(dired-rsync--extract-host-from-tramp FILE-OR-PATH &optional SPLIT-USER)
Documentation
Extract the tramp host part of FILE-OR-PATH.
It SPLIT-USER is set we remove the user@ part as well. We assume hosts don't need quoting.
Source Code
;; Defined in /nix/store/i42d1fmg6q3dci37c05j415vhqjrzi15-emacs-packages-deps/share/emacs/site-lisp/elpa/dired-rsync-20261005.758/dired-rsync.el
(defun dired-rsync--extract-host-from-tramp (file-or-path &optional split-user)
"Extract the tramp host part of FILE-OR-PATH.
It SPLIT-USER is set we remove the user@ part as well. We assume
hosts don't need quoting."
(with-parsed-tramp-file-name file-or-path tfop
(if (or split-user (not tfop-user))
tfop-host
(format "%s@%s" tfop-user tfop-host))))