mirror of
https://github.com/Homebrew/brew.git
synced 2025-07-14 16:09:03 +08:00

Rather than skip unlinking if there's no linked keg record, check to see whether the destination's realpath is the same as the source file in the keg being unlinked.
11 lines
215 B
Ruby
11 lines
215 B
Ruby
module Homebrew extend self
|
|
def unlink
|
|
raise KegUnspecifiedError if ARGV.named.empty?
|
|
|
|
ARGV.kegs.each do |keg|
|
|
print "Unlinking #{keg}... "
|
|
puts "#{keg.unlink} links removed"
|
|
end
|
|
end
|
|
end
|