untap: add --force switch

Co-authored-by: Eric Knibbe <enk3@outlook.com>
This commit is contained in:
Dawid Dziurla 2020-12-04 21:19:48 +01:00
parent 5f9140f8a8
commit e397f388f3
No known key found for this signature in database
GPG Key ID: 7B6D8368172E9B0B

View File

@ -36,7 +36,10 @@ module Homebrew
if installed_tap_formulae.length.positive? || installed_tap_casks.length.positive?
if args.force?
opoo "Untapping #{tap} even though it contains formulae or casks that are currently installed."
opoo <<~EOS
Untapping #{tap} even though it contains the following installed formulae or casks:
#{(installed_tap_formulae + installed_tap_casks.map(&:token)).join("\n")}
EOS
else
odie <<~EOS
Refusing to untap #{tap} because it contains the following installed formulae or casks: