From e524b7dd47a27fa208c56c86b29d440651c33f51 Mon Sep 17 00:00:00 2001 From: Issy Long Date: Thu, 24 Jul 2025 22:50:01 +0100 Subject: [PATCH] cmd/search: `--desc` depends on `--eval-all`, not the other way around - When the user tried `brew search foo` with `--eval-all` or its envvar, it would fail with `Error: Invalid usage: `--eval-all` cannot be passed without `--desc`.` - This was the wrong way around: `--desc` depends on `--eval-all`. --- Library/Homebrew/cmd/search.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Library/Homebrew/cmd/search.rb b/Library/Homebrew/cmd/search.rb index 92e700aeeb..e5bcda9e18 100644 --- a/Library/Homebrew/cmd/search.rb +++ b/Library/Homebrew/cmd/search.rb @@ -36,9 +36,9 @@ module Homebrew description: "Search for casks." switch "--desc", description: "Search for formulae with a description matching and casks with " \ - "a name or description matching ." + "a name or description matching .", + depends_on: "--eval-all" switch "--eval-all", - depends_on: "--desc", description: "Evaluate all available formulae and casks, whether installed or not, to search their " \ "descriptions.", env: :eval_all