Skip to content

cmd/version-install: add new command.#21418

Merged
MikeMcQuaid merged 2 commits intomainfrom
version_install
Jan 19, 2026
Merged

cmd/version-install: add new command.#21418
MikeMcQuaid merged 2 commits intomainfrom
version_install

Conversation

@MikeMcQuaid
Copy link
Copy Markdown
Member

Add new command to do brew tap-new, brew extract and brew install in one go.

People have been complaining about this forever so let's make it marginally easier for them by just wrapping commands we already have.

Copilot AI review requested due to automatic review settings January 18, 2026 01:30
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds a new brew version-install command that simplifies the process of installing specific versions of formulae by combining brew tap-new, brew extract, and brew install operations into a single command.

Changes:

  • Introduces a new version-install command that automates the creation of personal taps and extraction/installation of specific formula versions
  • Updates documentation across multiple files to recommend the new command instead of brew extract
  • Adds comprehensive test coverage for various usage scenarios
  • Updates shell completions for bash, zsh, and fish

Reviewed changes

Copilot reviewed 15 out of 16 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
Library/Homebrew/cmd/version-install.rb Main command implementation handling formula version extraction and installation
Library/Homebrew/test/cmd/version-install_spec.rb Comprehensive test suite covering multiple scenarios
docs/Versions.md Updated to recommend version-install over extract
docs/Tips-and-Tricks.md Updated command recommendation
docs/Manpage.md Added command documentation
docs/FAQ.md Updated references and formatting changes
manpages/brew.1 Added manpage entry for the command
completions/zsh/_brew Added zsh completion support
completions/fish/brew.fish Added fish completion support
completions/bash/brew Added bash completion support
completions/internal_commands_list.txt Registered new command
Library/Homebrew/formulary.rb Updated error message to reference new command
Library/Homebrew/cask/cask_loader.rb Updated error message to reference new command
Library/Homebrew/brew.sh Simplified developer command warning logic
Library/Homebrew/sorbet/rbi/dsl/homebrew/cmd/version_install.rbi Generated type definitions
AGENTS.md Added development guidelines and improved test recommendations
Files not reviewed (1)
  • Library/Homebrew/sorbet/rbi/dsl/homebrew/cmd/version_install.rbi: Language not supported

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copy link
Copy Markdown
Member

@p-linnane p-linnane left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Utter madness. Let's just ensure we're printing that this is unsupported like building from source.

@MikeMcQuaid
Copy link
Copy Markdown
Member Author

@p-linnane the messaging is:

You are responsible for maintaining this #{install_target}!
It will not receive any bugfix/security updates.
Homebrew cannot support it for you because we cannot maintain every formula
at every version or fix older versions in our Git history.

This lets people install arbitrary versions by creating their own local non-Git tap if it doesn't already exist and puts formulae in there.
@MikeMcQuaid
Copy link
Copy Markdown
Member Author

@p-linnane I think if we see people submitting stupid bug reports due to this I can also add a brew doctor check for having anything versioned installed from your default versions tap. It'll also already warn you about building from source.

@MikeMcQuaid MikeMcQuaid added this pull request to the merge queue Jan 19, 2026
Merged via the queue into main with commit 277c06d Jan 19, 2026
38 checks passed
@MikeMcQuaid MikeMcQuaid deleted the version_install branch January 19, 2026 09:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants