We've already disabled installing casks/formulae from URLs and we
regularly tell people not to install from paths so let's just deprecate
this behaviour entirely.
Even Homebrew developers do not need to work this way.
The way we handle boolean environment variables is a bit unfortunate.
For example, setting `HOMEBREW_EVAL_ALL=false` actually enables
`HOMEBREW_EVAL_ALL`.
Let's fix this by deprecating setting boolean environment variables to
common false-y values (`false`, `0`, `nil`, `no`, and `off`) so that we
can later ignore these false-y values when reading boolean environment
variables.
If you have `HOMEBREW_TEMP` set to a longer path (e.g. the user's
private temporary directory rather than `/private/tmp`), Sequoia will
error out on some tests when forking because the path is too long
(> 104 bytes).
To improve this situation let's:
- use a shorter path for `HOMEBREW_TEMP` by appending `/brew-tests` to
the existing `HOMEBREW_TEMP` used outside of tests rather than
creating nested temporary directories
- use the minimal amount of randomness to avoid collisions while
allowing parallel tests
- use `squeeze` to remove any double slashes in the temporary path
We will now build on Ventura (macOS 13) to Sequoia (macOS 15).
Runners for macOS 15-x86_64 will not be allocated by default due to a
lack of appropriate hardware.
Currently, ruby files that are not in the Cask directory are
considered to be formulae if a Formula or HomebrewFormula directory
doesn't exist which doesn't make sense. We know that these should
only be in a few directories so we can check for that explicitly.
Beyond that the `Tap#cask_file?` and `Tap.formula_file?` methods
were only used inside update-report so it doesn't make sense to
turn them into pathnames and expand things when we know that
each string will be a relative path from a tap that we can just
check with a regex.
This change will stop other tap changes like new commands or
changes to other directories like lib/ from showing up as new formulae.
I tried opening a PR for this a long time ago but I got busy
with other things and it got closed by the stale bot.
- https://github.com/Homebrew/brew/pull/15489
This should avoid these getting included globally in future.
I found this list from a combination of
https://github.com/Homebrew/brew/pull/17707/files, looking at the
Gemfile and just looking around myself.
Loading different constants can be tricky with all the requires in
Homebrew so we want to strengthen the existing checks to make
sure that things are not getting required when there is a performance
penalty. This expands the existing check to include more constants
beyond `Formula` that we don't expect to be defined and that pull
in a lot of other dependencies.