brew/Library/Homebrew/cmd/tap-pin.rb
2016-10-02 00:24:47 +02:00

19 lines
392 B
Ruby

#: * `tap-pin` <tap>:
#: Pin <tap>, prioritizing its formulae over core when formula names are supplied
#: by the user. See also `tap-unpin`.
require "tap"
module Homebrew
module_function
def tap_pin
ARGV.named.each do |name|
tap = Tap.fetch(name)
raise "pinning #{tap} is not allowed" if tap.core_tap?
tap.pin
ohai "Pinned #{tap}"
end
end
end