Commit Graph
50727 Commits
Author SHA1 Message Date
Mike McQuaidandGitHub 18185ee497 Merge pull request #22990 from DexM/shell-completions-fix
Install shell completions after artifacts are ready
6.0.8
2026-07-06 18:31:36 +00:00
Mike McQuaidandGitHub cc060c99ac Merge pull request #22987 from Homebrew/postinstall-link-steps
Add structured link install steps
2026-07-06 17:35:05 +00:00
Douglas EichelbergerandGitHub fa2c6df83d Merge pull request #22977 from Homebrew/upgrade-formula-lookup-perf
perf/upgrade: avoid linear scans of core formula names (~20% faster)
2026-07-06 17:09:41 +00:00
Mike McQuaidandGitHub c309c2a9d5 Merge pull request #22975 from Homebrew/tap-info-concurrent-to-hash
perf/tap-info: generate tap hashes concurrently (up to ~77% faster)
2026-07-06 17:05:31 +00:00
Mike McQuaid 6b0a4ddc00 Add structured link install steps
- Let JSON API post-install data express PostgreSQL's versioned public links.
- Fix PostgreSQL post-install ordering by running link steps before initdb.
- Add `link_dir` for recursive links that keep real extension dirs, skip
  `.DS_Store` and replace conflicting files or symlinks.
- Keep existing real target directories even when a source file or symlink
  maps to the same path.
- Add `link_children` for versioned executable links with implicit target
  paths and `HOMEBREW_PREFIX` as the link target default.
- Expand `#{name}`, `#{version}`, `#{version.major}` and
  `#{version.major_minor}` tokens from serialised step data.
- Normalise `path`, `source` and `target` values into typed path specs so
  runner methods do not need string-or-hash checks.
- Replace loose `T.untyped` install-step payloads with narrower aliases for
  raw steps, path specs, system arguments and template values.
- Keep Formula and Cask source or target base defaults intact while giving
  public link steps the prefix default needed by versioned formulae.
2026-07-06 17:53:02 +01:00
Douglas Eichelberger 1e81b7fc08 api: avoid linear scans of core formula names and cask tokens 2026-07-06 09:46:57 -07:00
Douglas Eichelberger 6f92c66c7e tap-info: generate tap JSON hashes concurrently 2026-07-06 09:43:14 -07:00
Douglas EichelbergerandGitHub bd67a64870 Merge pull request #22978 from Homebrew/tnochecks-noop-experiment
perf/sorbet: skip sorbet-runtime dispatch when runtime disabled (~6-8% faster)
2026-07-06 16:40:33 +00:00
Mike McQuaidandGitHub 42ee8b536a Merge pull request #22986 from Homebrew/fix-cask-upgrade-installed-version
Fix stale cask upgrade metadata
2026-07-06 16:39:59 +00:00
Kiril Piroženko 39470deb27 Install shell completions after artifacts are ready 2026-07-06 19:13:57 +03:00
Mike McQuaid dfcd620f40 Fix stale cask upgrade metadata
- Prefer the installed metadata path version over a stale tab when
  loading saved JSON cask metadata.
- This lets upgrades recover from receipts left behind by earlier
  successful cask upgrades.
- Add a regression covering two consecutive `local-caffeine` upgrades.
2026-07-06 17:13:51 +01:00
Mike McQuaidandGitHub b9fd955274 Merge pull request #22980 from HaraldNordgren/install-header-and-pretty-duration
Clarify install output for durations and single deps
2026-07-06 14:58:05 +00:00
Mike McQuaidandGitHub 08aaf39221 Merge pull request #22981 from Homebrew/sbom-bottle-manifest-supplements
Store bottle SBOM data in manifests
2026-07-06 14:21:16 +00:00
Mike McQuaid ed1724703d Store bottle SBOM data in manifests
- Keep bottled SBOMs reproducible by moving pour-specific runtime,
  compiler and bottle package data into package manifests.
- Preserve per-platform supplements for `:all` bottles so installs merge
  only the current platform data.
- Avoid validating full SBOMs during pour by appending manifest
  supplement arrays.
2026-07-06 15:01:55 +01:00
Sean MolenaarandGitHub 999af21685 Merge pull request #22982 from Homebrew/fix/docs/issue_link
Update issue links in docs to use correct template
2026-07-06 13:32:34 +00:00
Sean Molenaar 173a4827a7 Update issue links in docs to use correct template 2026-07-06 15:13:05 +02:00
Harald Nordgren 29cd62f216 Clarify install output for durations and single deps
Show the top-level formula header whenever any dependency was
installed first, not only when there were two or more, so the
transition from a dependency build to the formula build is clear.

Also format long build durations as hours and minutes and drop the
seconds once past five minutes, showing at most two units.
2026-07-06 13:12:05 +02:00
Mike McQuaidandGitHub 6457af0946 Merge pull request #22963 from danielfleischer/uv-bundle-source-option
Add source option to brew bundle uv tools
2026-07-06 07:30:20 +00:00
Mike McQuaidandGitHub 4c03d04228 Merge pull request #22972 from Homebrew/test_bot_spec-add-trust_store
test/test_bot_spec: use :trust_store context when testing trust
2026-07-06 07:24:06 +00:00
Mike McQuaidandGitHub deb84528da Merge pull request #22973 from Homebrew/test-bundle-brew
test/bundle/brew_spec: allow running test on generic OS
2026-07-06 07:24:03 +00:00
Daniel Fleischer f38e22f26a Add source option to brew bundle uv tools
Motivation:
`brew bundle dump` could not round-trip a uv tool installed from a
non-PyPI source. Installing with:

    uv tool install git+https://github.com/astral-sh/ruff.git

records the git source in uv's receipt, but `dump` emitted only
`uv "ruff"`, so restoring the Brewfile would reinstall from PyPI (or
fail) rather than the git repo. The source was lost because
`Uv.parse_tool_list` ran `uv tool list --show-with --show-extras`, which
never reports the source; uv only surfaces it via
`--show-version-specifiers` as `ruff v0.14 [required: git+https://...]`.

Changes:
- Request `--show-version-specifiers` and parse the `[required: ...]`
  segment, keeping it only when it is a real source (git/URL/path)
  rather than a bare version constraint like `>=0.1`.
- Add a `source:` Brewfile option to the uv DSL, validated as a String
  and stored only when present (mirrors flatpak's `url:` handling).
- Thread `source` through install (installs from the source instead of
  the name), dump (emits `, source: "..."`), and the already-installed
  check so `brew bundle check`/`cleanup` treat two tools with the same
  name but different sources as distinct.
- Extract the package-manager bootstrap in the base extension into
  `Extension.ensure_package_manager_installed!` so uv's overridden
  `preinstall!` reuses it instead of duplicating the logic.

Example Brewfile line now dumped and restored faithfully:

    uv "ruff", source: "git+https://github.com/astral-sh/ruff.git"

Methods added:
- Uv.parse_source / Uv.source_requirement? (extract + classify source)
- Uv.dump_source (read source from a package record)
- Uv#preinstall!, Uv#install!, Uv#package_installed?, Uv#dump_entry,
  Uv#installed_and_up_to_date? (source-aware overrides)
- Extension.ensure_package_manager_installed! (shared bootstrap)

Documented the option with an example in Brew-Bundle-and-Brewfile.md.

---------------------------------------------------

Address review feedback on the uv `source:` option:

- Extract the source-detection regex into a `SOURCE_REQUIREMENT_REGEX`
  constant and inline the single-use `source_requirement?` helper.
- Replace hard-to-read ternaries in `parse_source` and `dump_source`
  with early returns and a typed `package_source` helper, mirroring the
  `dump_with`/`package_with` pattern and dropping an unnecessary cast.
- Simplify `format_checkable` to pass entry options straight through (as
  Flatpak does), letting the typed extractors handle with/source.

--------------------------------------------------

Address uv bundle review feedback

- parse_source: fold the .git suffix into SOURCE_REQUIREMENT_REGEX so
  the check is a single match?.
- entry/package_source: use .fetch(:source, nil) to distinguish an
  unset source from an explicit nil.
- package_source: replace the silent is_a?(String) guard with a T.cast
  on the :source value, matching Flatpak (uv casts only the value since
  its options mix :with arrays with the :source string).
- Consolidate source stripping into a single normalize_source helper,
  used by entry, parse_source and normalized_options.
2026-07-06 09:47:17 +03:00
Douglas Eichelberger 78032164c4 standalone/sorbet: skip sorbet-runtime dispatch when runtime disabled 2026-07-05 23:27:58 -07:00
Douglas EichelbergerandGitHub 20ce57618d Merge pull request #22974 from dduugg/remove-redundant-t-lets
Remove redundant T.let annotations
6.0.7
2026-07-06 00:49:15 +00:00
Douglas Eichelberger 7ce8324e07 Remove redundant T.let from DEFAULT_CURL_ARGS
Without the annotation the frozen array constant infers as a
fixed-size tuple, which changed how Sorbet resolved the curl_output
calls that splat it, leaving stdout/status typed as NilClass and
SystemCommand::Result. Destructure via an explicit .to_a so the
multiple assignment typechecks against the tuple inference.
2026-07-05 17:31:51 -07:00
Douglas Eichelberger 3dec0b79b8 Remove redundant T.let annotations
Sorbet infers constant types from simple literals, literal arrays and
constructor calls (since 0.6.13304, including .freeze-d values), and
infers instance variable types assigned from signature parameters in
initialize. Remove T.let annotations that just restate those inferred
types, as found by the Sorbet/RedundantTLet and
Sorbet/RedundantTLetForLiteral cops proposed in
https://github.com/Shopify/rubocop-sorbet/pull/381.

dev-cmd/bump.rb's DEFAULT_CURL_ARGS is deliberately left annotated:
without T.let it infers as a fixed-size tuple, which changes how
Sorbet resolves the curl_output calls that splat it and fails brew
typecheck.
2026-07-05 17:24:26 -07:00
Michael Cho 5f70826a1d test/bundle/brew_spec: allow running test on generic OS 2026-07-05 17:20:16 -04:00
Michael Cho 05a8ee2972 test/test_bot_spec: use :trust_store context when testing trust 2026-07-05 16:40:09 -04:00
Mike McQuaidandGitHub aae17639c9 Merge pull request #22970 from Homebrew/sponsors-maintainers-man-completions
Update manpage and completions.
2026-07-05 20:09:32 +00:00
Mike McQuaidandGitHub 78e8b0e374 Merge pull request #22961 from Homebrew/install-steps-data-dirs
Add install step data directories
2026-07-05 19:55:10 +00:00
BrewTestBot 9fde83c34e Update manpage and completions.
Autogenerated by the [sponsors-maintainers-man-completions](https://github.com/Homebrew/brew/blob/HEAD/.github/workflows/sponsors-maintainers-man-completions.yml) workflow.
2026-07-05 19:52:48 +00:00
Mike McQuaid a8d048a10d Add install step data directories
- Model the existing PostgreSQL, MySQL and MariaDB initialisation patterns as
  named `init_data_dir` actions with their fixed marker and CI guards.
- Preserve API installs for database formulae that need post-install data
  bootstrapping without reopening arbitrary Ruby execution.
- Validate specialised `using:` values before creating data directories so
  invalid steps do not leave filesystem state behind.
- Keep permissions, ownership, PostgreSQL link maintenance and MySQL config
  warnings for separate named steps instead of overloading this DSL.
- Record that specialised `using:` variants require at least three current
  tap usages before they are added.
2026-07-05 20:36:30 +01:00
Mike McQuaidandGitHub d98e016817 Merge pull request #22965 from HaraldNordgren/info-bold-uninstalled-deps
info: bold dependencies of uninstalled packages
2026-07-05 19:34:23 +00:00
Michael ChoandGitHub 3dd092c77e Merge pull request #22968 from Homebrew/sponsors-maintainers-man-completions
Update manpage and completions.
2026-07-05 18:18:55 +00:00
Harald Nordgren 0391258cc9 info: bold dependencies of uninstalled formulae
`brew info <formula>` marked installed dependencies with a green ✔ but
left uninstalled ones (e.g. `llvm`) as plain text, so they were easy to
miss among the ticks.

Give `pretty_install_status` a nilable `bold:` flag:

- `true`  bold every entry, installed or not
- `false` never bold any entry
- `nil`   (default) bold installed entries only

`brew info`'s header and its dependency/requirement listings pass
`bold: true`, so the formula name and all of its deps render bold whether
or not they are installed. A dependency's red ✘ still only appears when
the formula itself is installed and the dependency is missing. Add a
`pretty_unmarked` helper for the bold-but-unmarked case.
2026-07-05 20:17:24 +02:00
Michael ChoandGitHub b93ae57fdb Merge pull request #22964 from Homebrew/test-bot-use-cache
test_bot/formulae: handle runtime deps similar to Formula
2026-07-05 18:08:44 +00:00
BrewTestBot df1566463e Update manpage and completions.
Autogenerated by the [sponsors-maintainers-man-completions](https://github.com/Homebrew/brew/blob/HEAD/.github/workflows/sponsors-maintainers-man-completions.yml) workflow.
2026-07-05 18:01:09 +00:00
Mike McQuaidandGitHub 4b09a4175b Merge pull request #22877 from okuramasafumi/improve-info-json
doc: Clarify version explanation of `--json` info
2026-07-05 17:53:45 +00:00
Mike McQuaidandGitHub 37a71530e3 Merge pull request #22967 from MiMoHo/cask-set-ownership-app-management
cask/staged: check App Management permissions before chown
2026-07-05 17:47:39 +00:00
Michael Cho f7d68caa06 test_bot/formulae: handle runtime deps similar to Formula
Previous calculation of dependencies would use default handler, which
omits optional and recommends but keeps build and test. This is
different from how `Formula#declared_runtime_dependencies` behaves which
omits build/test/optional but keeps recommends.
2026-07-05 13:47:16 -04:00
Mike McQuaidandGitHub 4151879b6f Merge pull request #22956 from Homebrew/bottle-sbom-metadata
Preserve bottled SBOMs on pour
2026-07-05 17:41:33 +00:00
Mike McQuaidandGitHub d327c8fdc9 Merge pull request #22952 from Homebrew/cask-json-caskroom-metadata
Store cask metadata as JSON more often
2026-07-05 17:39:58 +00:00
MiMoHoandClaude Fable 5 cfc2370b4e cask/staged: check App Management permissions before chown
`uninstall_preflight { set_ownership ... }` runs `sudo chown -R` on the
app bundle. On macOS 13 or later, modifying the contents of an app
bundle requires the App Management TCC permission even when running as
root, and `chown` does not trigger the system permission prompt:
without the permission, the uninstall aborts with one
`Operation not permitted` line per file in the bundle and no hint at
the actual cause.

Reuse Quarantine.app_management_permissions_granted? (already used for
upgrades in Cask::Artifact::Moved) before chowning, so that:

- the system permission prompt is triggered, letting the user grant
  access on the spot, and
- a clear, actionable CaskError is raised if the permission is missing.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-05 19:26:03 +02:00
Mike McQuaidandGitHub 0edaad13ed Merge pull request #22962 from Homebrew/cleanup-cask-download-cache
Prune stale cask downloads
2026-07-05 16:31:42 +00:00
Mike McQuaidandGitHub 6a86cdf436 Merge pull request #22960 from Homebrew/install-steps-bridge-order
Allow staged install step conversion
2026-07-05 16:30:56 +00:00
Mike McQuaidandGitHub 449acb172f Merge pull request #22955 from Homebrew/fix-self-migration-lock
Ignore same-name cask migrations
2026-07-05 16:27:58 +00:00
OKURA Masafumi d172e101f7 doc: Clarify version explanation of --json info 2026-07-06 00:13:52 +09:00
Mike McQuaid ca1c02b217 Handle broken cask cache links
- Treat missing cask cache targets as stale before timestamp checks
  so broken legacy symlinks cannot abort cleanup.
- Reuse one `Cask/` cache listing during legacy cask pruning to
  avoid repeated directory scans.
2026-07-05 16:09:24 +01:00
Mike McQuaid c20acf473c Allow staged install step conversion
- Let formula steps run before a remaining `post_install` so tap migrations
  can move repeated statements without blocking on unrelated Ruby work.
- Cover the main installer finish path so steps continue to run before
  `post_install` outside the explicit `brew postinstall` command.
- Keep the legacy conflict check as a TODO because side-by-side use is only
  a temporary conversion bridge.
- Make formula and cask DSL ordering reflect runtime order while the bridge
  exists.
- Record the final deprecation target and local tap verification workflow so
  follow-up tap PRs have a concrete success condition.
2026-07-05 16:08:45 +01:00
Mike McQuaid 38815faf2b Fix macOS dependency equality
- Include `bounds` in `UsesFromMacOSDependency#eql?` so Hash
  caches do not reuse formulae across different macOS bounds.
- Cover the equality case that made generic dependency expansion
  order-dependent.
2026-07-05 16:02:12 +01:00
Mike McQuaidandGitHub fe99b3b0ca Merge pull request #22959 from Homebrew/sponsors-maintainers-man-completions
Update manpage and completions.
2026-07-05 14:33:37 +00:00