BUG: `tramp-dissect-file-name' apparently used to return an array#39
BUG: `tramp-dissect-file-name' apparently used to return an array#39KarlHegbloom wants to merge 1 commit intononsequitur:masterfrom
Conversation
... but now it returns an object of type `tramp-file-name', which is a `cl-structure-class'.
|
Thanks for sending a PR for this (I just ran into this issue myself). Note that the |
|
I ran into the same bug, and here is my workaround (it also adds the missing support for non-default port): (defun git-gutter+-remote-default-directory (dir file)
(let* ((vec (tramp-dissect-file-name file))
(method (tramp-file-name-method vec))
(user (tramp-file-name-user vec))
(domain (tramp-file-name-domain vec))
(host (tramp-file-name-host vec))
(port (tramp-file-name-port vec)))
(tramp-make-tramp-file-name method user domain host port dir)))
(defun git-gutter+-remote-file-path (dir file)
(let ((file (tramp-file-name-localname (tramp-dissect-file-name file))))
(replace-regexp-in-string (concat "\\`" dir) "" file))) |
|
Can @yangsheng6810 's or @KarlHegbloom solution be merged into the package? What's holding it back? It'd be nice if magit-gutter-plus worked with TRAMP off-the-shelf. |
|
@yangsheng6810 Could you please merge it into the package? |
|
@beyondpie I am not the owner of this repo so I do not have the permission. I will submit a PR with my workaround though, after checking backward compatibility with older versions of Emacs |
|
@beyondpie PR submitted. |
... but now it returns an object of type
tramp-file-name', which is acl-structure-class'.