Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support specifying replacement formulae in deprecate! or disable! calls #18294

Closed
1 task done
carlocab opened this issue Sep 9, 2024 · 2 comments
Closed
1 task done
Labels
features New features help wanted We want help addressing this

Comments

@carlocab
Copy link
Member

carlocab commented Sep 9, 2024

Verification

Provide a detailed description of the proposed feature

A formula might do

deprecate! date: "3000-03-30", because: :unmaintained

or similarly with disable!. When this is set, brew info will show

Deprecated because it is not maintained upstream! It will be disabled on 3001-03-30.

We should add a new, optional, kwarg called replacement:, like so:

deprecate! date: "3000-03-30", because: :unmaintained, replacement: "better-software"

which will change the deprecation message to something like

Deprecated because it is not maintained upstream! It will be disabled on 3001-03-30.
Consider replacing it with:
    brew install better-software

What is the motivation for the feature?

Some formulae are deprecated and replaced by a formula of a different name. For example, exa and eza.

See also discussion at Homebrew/homebrew-core#183953.

How will the feature be relevant to at least 90% of Homebrew users?

It might not be, but it'll improve the experience of users of formulae that are deprecated/disabled.

What alternatives to the feature have been considered?

Leaving our handling of deprecate! and disable! unchanged.

@carlocab carlocab added the features New features label Sep 9, 2024
@MikeMcQuaid MikeMcQuaid added the help wanted We want help addressing this label Sep 9, 2024
@MikeMcQuaid
Copy link
Member

Great idea.

@alebcay
Copy link
Member

alebcay commented Nov 25, 2024

Implemented in #18733, shipped in https://github.com/Homebrew/brew/releases/tag/4.4.5, documented in #18810.

@alebcay alebcay closed this as completed Nov 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
features New features help wanted We want help addressing this
Projects
None yet
Development

No branches or pull requests

3 participants