-
-
Notifications
You must be signed in to change notification settings - Fork 10.8k
Description
Verification
- This issue's title and/or description do not reference a single formula e.g.
brew install wget. If they do, open an issue at https://github.com/Homebrew/homebrew-core/issues/new/choose instead.
Provide a detailed description of the proposed feature
Add new DSL that marks patch as "to be removed" with new version bump. It may be something like this:
patch do
url "<patch url>"
sha256 "<checksum>"
remove_with_version_bump!
end
# One of the ideas is to provide a way
# to add patch notes without using Ruby comments
patch do
url "<patch url>"
sha256 "<checksum>"
remove_with_version_bump! notes: "Some information about the patch",
issue_ref: "<PR or issue link>"
endSuch patches should be removed with brew bump-formula-pr and fail brew audit if they were not removed after version update (similar to how revision N works)
What is the motivation for the feature?
A lot of the patches we apply are either already merged by upstream or needed only for the specific version (f.e. version bump patches). Right now, it is fairly common when autobumped formula fails to apply the patch, so we need one maintainer who pulls the branch, removes no-longer-needed patches, pushes the changes, and waits for a second maintainer to approve it. If a formula has a lot of patches (let's say in cases like percona-server, where we have FreeBSD patches and some other), it may be difficult to identify which patches should stay or be removed. I believe adding new DSL would make managing patches easier
How will the feature be relevant to at least 90% of Homebrew users?
It is not relevant to non-contributors. The only benefit I could think of is that sometimes a formula will receive an update a bit faster
What alternatives to the feature have been considered?
Status quo