diff options
Diffstat (limited to 'Library/Homebrew/cmd')
| -rw-r--r-- | Library/Homebrew/cmd/uninstall.rb | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/Library/Homebrew/cmd/uninstall.rb b/Library/Homebrew/cmd/uninstall.rb index a05adece6..504ee9983 100644 --- a/Library/Homebrew/cmd/uninstall.rb +++ b/Library/Homebrew/cmd/uninstall.rb @@ -24,8 +24,7 @@ module Homebrew ARGV.kegs.group_by(&:rack) end - # --ignore-dependencies, to be consistent with install - if !ARGV.include?("--ignore-dependencies") && !ARGV.homebrew_developer? + if should_check_for_dependents? all_kegs = kegs_by_rack.values.flatten(1) return if check_for_dependents all_kegs end @@ -75,6 +74,13 @@ module Homebrew end end + def should_check_for_dependents? + # --ignore-dependencies, to be consistent with install + return false if ARGV.include?("--ignore-dependencies") + return false if ARGV.homebrew_developer? + true + end + def check_for_dependents(kegs) return false unless result = Keg.find_some_installed_dependents(kegs) |
