Last active
March 11, 2021 16:30
-
-
Save EtienneLem/77146b7804cd764b8e09d89f44a5a451 to your computer and use it in GitHub Desktop.
Homebrew, CocoaPods & rbenv ARM64 / X86_64 configuration
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Homebrew | |
case $(uname -m) in | |
"arm64") | |
export PATH="/opt/homebrew/bin:$PATH" | |
export RBENV_ROOT="/opt/homebrew/opt/rbenv" | |
;; | |
"x86_64") | |
export PATH="/usr/local/bin:$PATH" | |
export RBENV_ROOT="~/.rbenv" | |
;; | |
esac | |
# rbenv | |
export PATH="$RBENV_ROOT/bin:$PATH" | |
eval "$(rbenv init -)" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
At the time of this post, CocoaPods still isn’t compatible with arm64 (CocoaPods/CocoaPods#9907) and I figured a way to seamlessly have my terminal use the right
brew
/pod
/rbenv
based on the architecture.I’m using iTerm as my main terminal (arm64) and have Terminal.app configured with Open using Rosetta (x86_64).