Skip to main content

Manage different versions of homebrew packages

Project description

Brew Versions (brewv)

PyPI version Python versions

Manage multiple versions of your Homebrew packages with ease! Homebrew makes this difficult as a design decision, but sometimes old packages need to be installed and we need a way to do so easily.

Installation

With pipx

pipx install brew-versions

Or just with pip:

python3 -m pip install --user brew-versions

Usage

Switch to a specific version:

$ brewv switch wget 1.21
[brewv]: Switching wget to version 1.21
[brewv]: Not in cache: finding bottle to download
[brewv]: GET https://linuxbrew.bintray.com/bottles/wget-1.21.x86_64_linux.bottle.tar.gz
[brewv]: Bottle successfully downloaded, but cannot verify SHA256
[brewv]: Pinning wget
[brewv]: Successfully switched to wget 1.21

Installing from taps:

$ brewv switch jonchang/biology/bucky 1.4.4
[brewv]: Tapping jonchang/biology
[brewv]: Switching bucky to version 1.4.4
[brewv]: Not in cache: finding bottle to download
[brewv]: GET https://linuxbrew.bintray.com/bottles/bucky-1.4.4.x86_64_linux.bottle.tar.gz
[brewv]: No bottle was found for bucky 1.4.4
[brewv]: Searching for version in git directory, this may take a while...
[brewv]: Found a version in commit: eee76a60fb5d7c6b619d736b50ee10fe42a9c73c
[brewv]: Found bottle in tap config
[brewv]: GET https://dl.bintray.com/jonchang/bottles-biology/bucky-1.4.4.x86_64_linux.bottle.tar.gz
[brewv]: SHA256 verified successfully
[brewv]: Pinning bucky
[brewv]: Successfully switched to jonchang/biology/bucky 1.4.4

When no bottle is found for taps it will proceed with searching the local tap repository for the correct version and installing from the bottle defined in the formula if it exists, otherwise from source.

This is very slow for the main homebrew repository so this behaviour is disabled when a bottle for a homebrew-core package cannot be found. You can supply the option brewv switch --slow ... to perform this search.

Warnings

Proper SHA256 verification is not done when downloading bottles from the main bottle repository. This is because to get the expected SHAs would mean searching the huge homebrew-core repository.

While homebrew bottles exist for most operating systems, if the bottle is not found then parsing old formulas fails quite often since Homebrew updates their code frequently.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

brew-versions-0.3.2.tar.gz (10.3 kB view details)

Uploaded Source

Built Distribution

brew_versions-0.3.2-py3-none-any.whl (9.3 kB view details)

Uploaded Python 3

File details

Details for the file brew-versions-0.3.2.tar.gz.

File metadata

  • Download URL: brew-versions-0.3.2.tar.gz
  • Upload date:
  • Size: 10.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.0.0 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.9.4

File hashes

Hashes for brew-versions-0.3.2.tar.gz
Algorithm Hash digest
SHA256 ae0cbbee3d6c5af28c8c4fc7752afef211daa6bdb920b95b49df8c4b4c695e03
MD5 a988254b3dc5a7cd158429f99adcd129
BLAKE2b-256 462e6e752c5c101bb6b8bbe8839914fe8696992aba603d74d02d8a8bcd51493b

See more details on using hashes here.

File details

Details for the file brew_versions-0.3.2-py3-none-any.whl.

File metadata

  • Download URL: brew_versions-0.3.2-py3-none-any.whl
  • Upload date:
  • Size: 9.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.0.0 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.9.4

File hashes

Hashes for brew_versions-0.3.2-py3-none-any.whl
Algorithm Hash digest
SHA256 741c4aad1d6f8c651769873619cf5fe6a7b1d11070416cf3c979d2b86475dd1f
MD5 d5feb2819a5d488c232fc07bde90769b
BLAKE2b-256 7739e31a06e773adab29b14daaeb3c205c6db6d054c36311075240193549ba62

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page