aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Homebrew/cmd/untap.rb
blob: be91191b50914cb6175c4f33b0b4981bb0b65299 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#:  * `untap` <tap>:
#:    Remove a tapped repository.

require "tap"

module Homebrew
  def untap
    raise "Usage is `brew untap <tap-name>`" if ARGV.empty?

    ARGV.named.each do |tapname|
      tap = Tap.fetch(tapname)
      raise "untapping #{tap} is not allowed" if tap.core_tap?
      tap.uninstall
    end
  end
end