This will become the default in a later version of Homebrew but has an
opt-out through HOMEBREW_NO_INSTALL_CLEANUP.
Also, always cleanup files older than 120 days and set the general
default value for "old" logs, casks etc. to 30 days.
* update references in `--cc` flag, using modern gcc examples
* note that issues should not be filed if `--cc` flag is used
* remove reference to `HOMEBREW_CC` as it should not be exposed to users
* generate manpages using `brew man` with these changes
If people are trying to `brew install` an existing version it’s worth
pointing out to them how they can reinstall (as it’s pretty much the
only case where we’re not already suggesting another command).
Allow at `install` (or `install --only-dependencies`) time to specify
that test dependencies should be installed. This will allow simplifying
code in `brew test-bot`.
This could also be made an environment variable if desired by
maintainers.
Improve the messaging around `brew install` when there's a possible user
action such as an `upgrade` or `link` and don't tell people to
`install --force` when it's unnecessary.
While I did this, tweak the output and function usage in a couple of
related places.
Some example output before this change:
```
Warning: openssl is a keg-only and another version is linked to opt.
Use `brew install --force` if you want to install this version
Warning: mysql@5.6 is a keg-only and another version is linked to opt.
Use `brew install --force` if you want to install this version
Warning: analog-6.0_1 already installed
Warning: bash-completion@2-2.5 already installed, it's just not linked.
```
Some example output after this change:
```
Error: openssl 1.0.2k is already installed
To upgrade to 1.0.2l, run `brew upgrade openssl`
Warning: mysql@5.6 5.6.36_1 is already installed
Warning: analog 6.0_1 is already installed
Warning: bash-completion@2 2.5 is already installed, it's just not linked.
You can use `brew link bash-completion@2` to link this version.
```
When reproducing issues with software that hasn’t been bottled yet on
your version of macOS it can sometimes be helpful to use `or_later`
bottle functionality i.e. just use the bottle for the latest version of
macOS available. This maps well to the existing `--force-bottle`
argument so it will now act as if the latest bottle has a `or_later`
ending.
* installing HEAD keg_only should be possible only if:
1.
- Old version installed differs from new one and optlinked
- `--force` flag is passed
- HEAD is seriously outdated or outdated with `--fetch-HEAD`
or 2.
- Old version installed differs from new one and not optlinked
or 3.
- This formula is not installed
* installing keg_only should be possible only if:
1.
- Old version installed differs from new one and optlinked
- `--force` flag is passed
or 2.
- Old version installed differs from new one and not optlinked
or 3.
- This formula is not installed
* installing HEAD should be possible only if:
1.
- Old HEAD is seriously outdated or outdated with `--fetch-HEAD`
or 2.
- HEAD is not installed
* installing stable or devel should be possible only if:
- Old version installed differs from new one