Unverified Commit ed94e06d authored by Hielke Walinga's avatar Hielke Walinga Committed by GitHub
Browse files

command-not-found: speed up call to Homebrew command-not-found (#7740)

By sourcing brew files directly we can achieve a very high speed up.
This will not work if the user installed homebrew in a different
location than by default.
parent e65bce84
......@@ -26,10 +26,8 @@ fi
# OSX command-not-found support
# https://github.com/Homebrew/homebrew-command-not-found
if type brew &> /dev/null; then
if brew command command-not-found-init > /dev/null 2>&1; then
eval "$(brew command-not-found-init)";
fi
if [[ -s '/usr/local/Homebrew/Library/Taps/homebrew/homebrew-command-not-found/handler.sh' ]]; then
source '/usr/local/Homebrew/Library/Taps/homebrew/homebrew-command-not-found/handler.sh'
fi
# NixOS command-not-found support
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment