all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Michael Albinus <michael.albinus@gmx.de>
To: "Luiz Romário Santana Rios" <luizromario@tecgraf.puc-rio.br>
Cc: help-gnu-emacs@gnu.org
Subject: Re: tramp-sshfs doesn't seem to respect tramp-remote-path
Date: Thu, 08 Aug 2024 15:30:16 +0200	[thread overview]
Message-ID: <87r0azkuqf.fsf@gmx.de> (raw)
In-Reply-To: <0359c325-007d-4cae-82b7-c262214c33a2@tecgraf.puc-rio.br> ("Luiz Romário Santana Rios"'s message of "Thu, 8 Aug 2024 10:13:00 -0300")

Luiz Romário Santana Rios <luizromario@tecgraf.puc-rio.br> writes:

Hi,

> Thanks for the answer. I looked into this a little bit further and,
> looking into the code for `tramp-sshfs-handle-exec-path`:
>
> (defun tramp-sshfs-handle-exec-path ()
>   "Like `exec-path' for Tramp files."
>   (append
>    (with-parsed-tramp-file-name default-directory nil
>      (with-tramp-connection-property (tramp-get-process v) "remote-path"
>        (with-temp-buffer
>          (let (process-file-side-effects)
>        (process-file "getconf" nil t nil "PATH"))
>      ;; ...
>
> it seems to query the "remote-path" property. Only if the query fails,
> does it get the default "PATH" variable from getconf (which is exactly
> the "/bin:/usr/bin" I've been getting). Why does the query to
> "remote-path" fail?

The 'query the "remote-path" property' looks into the Tramp cache for
the given connection. If there is a value, it is used. Otherwise, the
code is executed, which is (process-file "getconf" nil t nil "PATH").

The result is stored in the cache; next time the function is called it
uses the cached result.

Best regards, Michael.



  reply	other threads:[~2024-08-08 13:30 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-07-30 13:22 tramp-sshfs doesn't seem to respect tramp-remote-path Luiz Romário Santana Rios
2024-07-30 16:47 ` Michael Albinus
2024-07-30 21:28   ` Luiz Romário Santana Rios
2024-07-31 11:47     ` Michael Albinus
2024-07-31 15:18       ` Luiz Romário Santana Rios
2024-07-31 16:43         ` Michael Albinus
2024-08-08 13:13           ` Luiz Romário Santana Rios
2024-08-08 13:30             ` Michael Albinus [this message]
2024-08-08 13:37               ` Luiz Romário Santana Rios
2024-08-08 14:23                 ` Michael Albinus
2024-08-08 15:18                   ` Luiz Romário Santana Rios
2024-08-08 15:24                     ` Michael Albinus
2024-08-08 17:33                       ` Michael Albinus

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87r0azkuqf.fsf@gmx.de \
    --to=michael.albinus@gmx.de \
    --cc=help-gnu-emacs@gnu.org \
    --cc=luizromario@tecgraf.puc-rio.br \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.