all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: "Gerd Möllmann" <gerd.moellmann@gmail.com>
To: Stefan Kangas <stefankangas@gmail.com>
Cc: 71235@debbugs.gnu.org,
	"Mattias Engdegård" <mattias.engdegard@gmail.com>,
	"Michael Albinus" <michael.albinus@gmx.de>
Subject: bug#71235: Failing test on macOS: tramp-test17-dired-with-wildcards
Date: Sun, 02 Jun 2024 16:03:20 +0200	[thread overview]
Message-ID: <m2le3nv3vb.fsf@pro2.fritz.box> (raw)
In-Reply-To: <CADwFkmkk_Ry2WignMm3vqkAdtaEdrdek_7Zb4HVtJZw4tirdjw@mail.gmail.com> (Stefan Kangas's message of "Sun, 2 Jun 2024 11:04:36 +0000")

Stefan Kangas <stefankangas@gmail.com> writes:

> Michael Albinus <michael.albinus@gmx.de> writes:
>
>>>     (executable-find "gls")
>>>     => "/opt/homebrew/bin/gls"
>>
>> Hmm. Should we add "/opt/homebrew/bin" to the default
>> tramp-remote-path? It looks very special, even on macOS.
>>
>> OTOH, we have directories like "/local/freeware/bin", "/local/gnu/bin",
>> "/usr/freeware/bin", "/usr/pkg/bin", "/usr/contrib/bin", "/opt/bin",
>> "/opt/sbin" and "/opt/local/bin" there, which are also special.
>
> AFAIK, this is the default location where Homebrew (https://brew.sh/)
> puts binaries, at least on new installations.  (The Homebrew directory
> structure has changed slightly over the years, but I don't know if this
> is one of them since I only noticed it those changes passing.)
>
> I think it might make sense to add it to `tramp-remote-path`, but I'm
> not familiar enough with Tramp to understand all the implications of
> doing so.  I'm copying in Mattias and Gerd, who I believe are using
> macOS, in case they have anything to add.

Homebrew uses different directories depending on if it's on a mac with
x64 or arm64. I have both, and find the easiest thing to do is to use
the brew shellenv command in my .zshenv to set up things. (I have a
common dotfles setup for my machines.)

  /Users/gerd % brew shellenv 
  export HOMEBREW_PREFIX="/opt/homebrew";
  export HOMEBREW_CELLAR="/opt/homebrew/Cellar";
  export HOMEBREW_REPOSITORY="/opt/homebrew";
  export PATH="/opt/homebrew/bin:/opt/homebrew/sbin${PATH+:$PATH}";
  export MANPATH="/opt/homebrew/share/man${MANPATH+:$MANPATH}:";
  export INFOPATH="/opt/homebrew/share/info:${INFOPATH:-}";

Then, I'm using exec-path-from-shell in my init.el to get the shell
environment into Emacs, even when started from Emacs.app. Starting an
.app bundle doesn't involve the shell, so one has to do something.

Works like a charm with everything I use, including things like Magit
over tramp, and so on.

(If you are using zsh from Homebrew and not the one from macOS, you
might want to call connection-local-set-profile-variables or something
to get the right zsh.)





  parent reply	other threads:[~2024-06-02 14:03 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-05-27 21:32 bug#71235: Failing test on macOS: tramp-test17-dired-with-wildcards Stefan Kangas
2024-05-28  7:44 ` Michael Albinus via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-05-28 22:56   ` Stefan Kangas
2024-05-29  7:28     ` Michael Albinus via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-05-29 20:51       ` Stefan Kangas
2024-05-30  8:54         ` Michael Albinus via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-05-30 12:12     ` Michael Albinus via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-05-31  9:22       ` Michael Albinus via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-06-02 10:37         ` Stefan Kangas
2024-06-02 10:19       ` Stefan Kangas
2024-06-02 10:33         ` Michael Albinus via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-06-02 11:04           ` Stefan Kangas
2024-06-02 11:07             ` Stefan Kangas
2024-06-02 13:14             ` Michael Albinus via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-06-02 17:51               ` Stefan Kangas
2024-06-02 14:03             ` Gerd Möllmann [this message]
2024-06-02 14:23               ` Michael Albinus via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-06-02 14:46                 ` Gerd Möllmann
2024-06-02 14:55                   ` Michael Albinus via Bug reports for GNU Emacs, the Swiss army knife of text editors

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=m2le3nv3vb.fsf@pro2.fritz.box \
    --to=gerd.moellmann@gmail.com \
    --cc=71235@debbugs.gnu.org \
    --cc=mattias.engdegard@gmail.com \
    --cc=michael.albinus@gmx.de \
    --cc=stefankangas@gmail.com \
    /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.