From e5986dba6cb3299c1ddb44049e21ba5e1ac0bfae Mon Sep 17 00:00:00 2001 From: ylht Date: Mon, 19 Jul 2021 09:55:30 +0800 Subject: [PATCH] cmd/doctor: repair `xattr` not find --- Library/Homebrew/cask/quarantine.rb | 2 +- Library/Homebrew/diagnostic.rb | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Library/Homebrew/cask/quarantine.rb b/Library/Homebrew/cask/quarantine.rb index f0c60ac038..e8256638dd 100644 --- a/Library/Homebrew/cask/quarantine.rb +++ b/Library/Homebrew/cask/quarantine.rb @@ -31,7 +31,7 @@ module Cask def check_quarantine_support odebug "Checking quarantine support" - if !system_command(xattr, print_stderr: false).success? + if !system_command(xattr, args:[ "-h" ], print_stderr: false).success? odebug "There's no working version of `xattr` on this system." :xattr_broken elsif swift.nil? diff --git a/Library/Homebrew/diagnostic.rb b/Library/Homebrew/diagnostic.rb index 5b08bb8ea8..54b5a5dac9 100644 --- a/Library/Homebrew/diagnostic.rb +++ b/Library/Homebrew/diagnostic.rb @@ -1000,7 +1000,7 @@ module Homebrew end def check_cask_xattr - result = system_command "/usr/bin/xattr" + result = system_command "/usr/bin/xattr", args: [ "-h" ] return if result.status.success?