I just changed my MacBook for an ARM CPU and I am trying to make my projects work.
I need PHP 7.4 for one of them.
Homebrew is not supposed to work on arm for now but you can still install it in /opt/homebrew which I did.
brew install php@7.4 worked fine and /opt/homebrew/Cellar/php/7.2.14/bin/php -v gives me the right version of PHP.
I add PATH="/opt/homebrew/Cellar/php/7.2.14/bin:${PATH}" in my ~/.bash_profile and made source ~/.bash_profile.
But php -v still gives me 7.3 version, any idea how to use 7.4 by default?