GNU bug report logs -
#76165
[PATCH] ansi-osc-directory-tracker respects Tramp remote files
Previous Next
Reported by: Ship Mints <shipmints <at> gmail.com>
Date: Sun, 9 Feb 2025 19:06:01 UTC
Severity: normal
Tags: patch
Fixed in version 31.1
Done: Michael Albinus <michael.albinus <at> gmx.de>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
Visuwesh <visuweshm <at> gmail.com> writes:
Hi,
> That reminds me why my :override advice was simpler. Indeed, I had to
> get rid of that test to ensure that the function would work as intended
> for remote shell buffers. It never made much sense IMO and I got the
> impression that it is in place as a "let's be absolutely sure" measure.
> I can say that I face no issues with the test omitted thus far. It could
> be a product of me being in control of $PS1 for local and remote shells
> though.
Well. The host part of the URL could be anything, and must not be the
same like the current host name. So perhaps the check could be like
this, "to be absolutely sure":
--8<---------------cut here---------------start------------->8---
(when-let* ((url (url-generic-parse-url text))
((string= (url-type url) "file"))
((or (null (url-host url))
;; Use `downcase' to match `url-generic-parse-url' behavior
(string= (url-host url)
(downcase
(or (file-remote-p default-directory 'host)
(system-name)))))))
(ignore-errors
(cd-absolute
(concat (file-remote-p default-directory)
(url-unhex-string (url-filename url)))))))
--8<---------------cut here---------------end--------------->8---
WDYT?
Best regards, Michael.
This bug report was last modified 151 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.