unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
From: Michael Albinus <michael.albinus@gmx.de>
To: "André A. Gomes" <andremegafone@gmail.com>
Cc: help-gnu-emacs@gnu.org
Subject: Re: Retrieve values of variables in remote files
Date: Sat, 07 Jan 2023 13:20:41 +0100	[thread overview]
Message-ID: <87v8lir0x2.fsf@gmx.de> (raw)
In-Reply-To: <87k01z7p9b.fsf@gmail.com> ("André A. Gomes"'s message of "Fri, 06 Jan 2023 15:42:56 +0200")

André A. Gomes <andremegafone@gmail.com> writes:

> Hi,

Hi André,

> I expected that running the following on a remote Tramp buffer would
> give me the right value.
>
> (with-connection-local-variables shell-file-name)
> => "/bin/sh"
>
> The right value would be "/data/data/com.termux/files/urs/bin/bash"
> since this is a remote buffer on Termux.

Yes, but you must teach Tramp to know this. Tramp speaks about this in
its manual (info "(tramp) Android shell setup") but you can use that for
any other remote Termux setup.

What is the value of variables connection-local-criteria-alist,
connection-local-profile-alist and connection-local-variables-alist,
evaluated in the respective buffer?

> I'm a bit surprised since xref-matches-in-files uses
> with-connection-local-variables and it always gets the right values.

Btw, which Emacs version / Tramp version are you using?

> Any idea?  Thank you.

Best regards, Michael.



  reply	other threads:[~2023-01-07 12:20 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-01-06 13:42 Retrieve values of variables in remote files André A. Gomes
2023-01-07 12:20 ` Michael Albinus [this message]
2023-01-10 12:39   ` André A. Gomes
2023-01-10 14:11     ` Michael Albinus
2023-01-10 14:57       ` André A. Gomes

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

  List information: https://www.gnu.org/software/emacs/

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

  git send-email \
    --in-reply-to=87v8lir0x2.fsf@gmx.de \
    --to=michael.albinus@gmx.de \
    --cc=andremegafone@gmail.com \
    --cc=help-gnu-emacs@gnu.org \
    /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.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).