From fc2624997b1439db2024d8f00ddfdb0dcdf24d37 Mon Sep 17 00:00:00 2001 From: Abhineet Date: Tue, 13 Dec 2022 20:03:10 +0530 Subject: [PATCH] Fix sourcing of asdf.sh (#710) Installing asdf via Homebrew now requires souring from a different path. This same issue was recently fixed in thoughbot/laptop by @cpytel, and so I've copied the changes from this commit: https://github.com/thoughtbot/laptop/commit/aa3a84e15e76af9bf3713c350354bc42e59749bc --- zsh/configs/post/path.zsh | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/zsh/configs/post/path.zsh b/zsh/configs/post/path.zsh index 284983b..6f1b5ca 100644 --- a/zsh/configs/post/path.zsh +++ b/zsh/configs/post/path.zsh @@ -5,9 +5,7 @@ PATH="$HOME/.bin:/usr/local/sbin:$PATH" if [ -f "$HOME/.asdf/asdf.sh" ]; then . "$HOME/.asdf/asdf.sh" elif which brew >/dev/null && - BREW_DIR="$(dirname `which brew`)/.." && - [ -f "$BREW_DIR/opt/asdf/asdf.sh" ]; then - . "$BREW_DIR/opt/asdf/asdf.sh" + . "$(brew --prefix asdf)/libexec/asdf.sh" fi # mkdir .git/safe in the root of repositories you trust