class TapDance::Tap
Attributes
name[RW]
url[RW]
Public Class Methods
new(name, url, opts={})
click to toggle source
# File lib/tap_dance/tap.rb, line 9 def initialize(name, url, opts={}) @name = name.to_sym @url = url.to_s @opts = opts end
Public Instance Methods
entap()
click to toggle source
# File lib/tap_dance/tap.rb, line 15 def entap BrewCLI.tap(@url) end
tapped?()
click to toggle source
# File lib/tap_dance/tap.rb, line 23 def tapped? BrewCLI.tap_list.out.each_line { |t| return true if @url == t.strip } return false end
to_s()
click to toggle source
# File lib/tap_dance/tap.rb, line 31 def to_s "#{@name}:#{@url}" end
untap()
click to toggle source
# File lib/tap_dance/tap.rb, line 19 def untap BrewCLI.untap(@url) end