I have the need to test a package (Ansible in this case) at HEAD, but also need to use it regularly in Stable.
As the GitHub request to add a
--stable flag was closed (which would actually make a lot of sense in a use case like this), I’m attempting to use brew switch to do this.
Currently, I’m attempting to use
brew switch ansible 2.9.6_1 to switch to the Stable version, and
brew switch ansible HEAD-e785bda_1 to switch to HEAD (as I’m waiting for a fix in Ansible_2.10, but it isn’t released yet).
Ideally, switching to HEAD might only require
HEAD rather than the specific Git commit ID (though I do logically understand the reasons for this).
In the cases of simply installing HEAD, it would also be nice to get a flag added to
switch that was
--stable to switch back to the most recent stable version, or install the most recent version. If I installed Ansible via
brew install --HEAD ansible, I would love to be able to reinstall stable perhaps by simple
brew reinstall --stable ansible. Similarly,
brew switch --stable or
brew switch --head, etc.
Are there ways to accomplish this, as it stands today other than the “hit it with a hammer” method of unlink or uninstall?