Skip to content

fix(upgrade): ignore benign Homebrew stderr during package upgrades#603

Open
matracey wants to merge 1 commit intoburesdv:mainfrom
matracey:main
Open

fix(upgrade): ignore benign Homebrew stderr during package upgrades#603
matracey wants to merge 1 commit intoburesdv:mainfrom
matracey:main

Conversation

@matracey
Copy link
Copy Markdown

Problem

Homebrew writes progress and status messages to stderr by design (not just errors). For example, lines like:

  • ✅ Bottle frei0r (2.5.6)
  • ==> Downloading ...
  • 🍺 /usr/local/Cellar/...

Cork treats nearly all stderr output as errors, so every successful upgrade produces a "Packages updated with errors" dialog — even though nothing actually failed.

Fix

Expand the ignorable stderr pattern list in Update Packages.swift to cover common benign Homebrew output:

Pattern Reason
Bottle Bottle download/pour status
Fetching Dependency fetching
Downloading Download progress
Already downloaded Cached bottle
Pouring Bottle installation
Installing Package installation
🍺 Homebrew success indicator
Homebrew success indicator
==> Homebrew section headers
Empty lines Blank stderr output

The existing tap and No checksum defined for patterns are preserved.

Only genuinely unexpected stderr output will now trigger the error dialog.

Notes

  • Homebrew is not localized — all CLI output is hardcoded English, so these patterns are locale-agnostic.
  • The emoji patterns (, 🍺) are not language-dependent either.

Homebrew writes progress and status messages (e.g. "✅ Bottle frei0r
(2.5.6)") to stderr by design. Cork was treating nearly all stderr
output as errors, causing a false "Packages updated with errors" dialog
after every successful upgrade.

Expand the ignorable stderr pattern list to cover common benign
Homebrew output: Bottle, Fetching, Downloading, Pouring, Installing,
section headers (==>), success indicators (✅, 🍺), and blank lines.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant