You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Then repeated sourcing of .zshrc results in no change, because the shellenv command is smart enough to understand if the necessary things are already in the path, and emits nothing if they are.
Repeated execution of the two commands together, however, results in infinitely growing PATH, MANPATH and INFOPATH variables because the code in shellenv doesn't understand the contribution from the 'other' architecture.
I can, of course conditionally execute these commands in scripts, but since there is already some logic in shellenv to detect repetitive execution I wondered if it could be extended to become smarter.
What is the motivation for the feature?
Less per-install custom scripting around the management of Homebrew environments.
How will the feature be relevant to at least 90% of Homebrew users?
I think arm/intel mixes are somewhat common, as github don't supply runners that can build arm64 binaries.
What alternatives to the feature have been considered?
I can script around the problem, obviously.
The text was updated successfully, but these errors were encountered:
Repeated execution of the two commands together, however, results in infinitely growing PATH, MANPATH and INFOPATH variables because the code in shellenv doesn't understand the contribution from the 'other' architecture.
This is somewhat intentional: brew shellenv is checking that the its installation is first in the PATH and running the other brew shellenv breaks that logic. As a result, yeh, you're better to either use custom logic here or not use brew shellenv for one of the environments. There's no real way otherwise for it to be able to tell what you want it to do.
I guess another approach might be (for arm only) detect the intel, and add both in a single call. Assume if someone installed both architectures, they want to execute both prioritising the native one, which I think is not unreasonable.
Verification
brew install wget
. If they do, open an issue at https://github.com/Homebrew/homebrew-core/issues/new/choose instead.Provide a detailed description of the proposed feature
I'd like to add both intel and arm Homebrew paths to my environment, because I've got a mix of packages from each brew architecture.
What I'd like to do, is add a couple of commands to ~/.zshrc
If I have only one of these, e.g.
Then repeated sourcing of .zshrc results in no change, because the shellenv command is smart enough to understand if the necessary things are already in the path, and emits nothing if they are.
Repeated execution of the two commands together, however, results in infinitely growing PATH, MANPATH and INFOPATH variables because the code in shellenv doesn't understand the contribution from the 'other' architecture.
I can, of course conditionally execute these commands in scripts, but since there is already some logic in shellenv to detect repetitive execution I wondered if it could be extended to become smarter.
What is the motivation for the feature?
Less per-install custom scripting around the management of Homebrew environments.
How will the feature be relevant to at least 90% of Homebrew users?
I think arm/intel mixes are somewhat common, as github don't supply runners that can build arm64 binaries.
What alternatives to the feature have been considered?
I can script around the problem, obviously.
The text was updated successfully, but these errors were encountered: