-
-
Notifications
You must be signed in to change notification settings - Fork 10.9k
Description
brew doctor output
n/aVerification
- I ran
brew updatetwice and am still able to reproduce my issue. - My "
brew doctoroutput" above saysYour system is ready to brewor a definitely unrelatedTiermessage. - This issue's title and/or description do not reference a single formula e.g.
brew install wget. If they do, open an issue at https://github.com/Homebrew/homebrew-core/issues/new/choose instead.
brew config output
n/aWhat were you trying to do (and why)?
Open a shell and have homebrew work.
What happened (include all command output)?
fish: Unknown command: 'fpath[1,0]=/opt/homebrew/share/zsh/site-functions'
~/.config/fish/spec.d/os/darwin/homebrew.fish (line 1):
export HOMEBREW_PREFIX="/opt/homebrew"; export HOMEBREW_CELLAR="/opt/homebrew/Cellar"; export HOMEBREW_REPOSITORY="/opt/homebrew"; fpath[1,0]="/opt/homebrew/share/zsh/site-functions"; eval "$(/usr/bin/env PATH_HELPER_ROOT="/opt/homebrew" /usr/libexec/path_helper -s)" [ -z "${MANPATH-}" ] || export MANPATH=":${MANPATH#:}"; export INFOPATH="/opt/homebrew/share/info:${INFOPATH:-}";
etc...
What did you expect to happen?
Working homebrew commands.
Step-by-step reproduction instructions (by running brew commands)
- run fish shell on MacOS
/opt/homebrew/bin/brew shellenv- Observe the very much not fish shell code you get.
This problem stems from the changes made in #21374, and was reported in #21382, which was closed with the advice to call shellenv fish. I don't think that's an easy solution to find, so I'd like to open another bug. The code may be simplified and that may be a good thing, but now it no longer does something it once did correctly (detect fish shell), and results in inscrutable breakage. That's at the very least a bug or a doc change, though ideally it would come with a grace period for people to make the switch if dropping support was the idea.
It took me quite a while to track down this problem, and I eventually figured out that the upgrade must have changed something and found the (closed) github issue.
Please consider fixing this behavior, or temporarily reverting it and adding a warning for fish shell users for a set grace period. It will avoid a lot of breakage and save people from having to track down the github issue.