Skip to content

Exit non-zero when pinning uninstalled formula #20213

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jul 4, 2025
Merged

Exit non-zero when pinning uninstalled formula #20213

merged 2 commits into from
Jul 4, 2025

Conversation

dduugg
Copy link
Member

@dduugg dduugg commented Jul 4, 2025

  • Have you followed the guidelines in our Contributing document?
  • Have you checked to ensure there aren't other open Pull Requests for the same change?
  • Have you added an explanation of what your changes do and why you'd like us to include them?
  • Have you written new tests for your changes? Here's an example.
  • Have you successfully run brew style with your changes locally?
  • Have you successfully run brew typecheck with your changes locally?
  • Have you successfully run brew tests with your changes locally?

Resolves #20205

(This will now also exit non-zero when pinning an already pinned formula.)

@Bo98
Copy link
Member

Bo98 commented Jul 4, 2025

This will now also exit non-zero when pinning an already pinned formula

I'd be cautious of this as we intentionally do not exit non-zero for already installed formulae for brew install. It makes it easier to script. Even here, it was always a warning and not an error.

@dduugg
Copy link
Member Author

dduugg commented Jul 4, 2025

Ok, i'll revert that one. It's more of a no-op than error.

@dduugg
Copy link
Member Author

dduugg commented Jul 4, 2025

PTAL @Bo98

@dduugg dduugg added this pull request to the merge queue Jul 4, 2025
Merged via the queue into main with commit 43b72d3 Jul 4, 2025
33 checks passed
@dduugg dduugg deleted the dug-20205 branch July 4, 2025 22:09
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.

brew pin on package that isn't installed prints error but exits with code 0
3 participants