tfswitch is available for MacOS and Linux based operating systems.
Installation for MacOS is the easiest with Homebrew. If you do not have homebrew installed, click here.
brew install warrensbox/tap/tfswitch
Installation for Linux operation systems.
curl -L https://raw.githubusercontent.com/warrensbox/terraform-switcher/release/install.sh | bash
Snapcraft for CentOS, Ubuntu, Linux Mint, RHEL, Debian, Fedora
sudo snap install tfswitch
Install from source
Alternatively, you can install the binary from the source here.