Merge pull request #846 from vladshablinsky/pinned_not_eligible

formula: pinned keg is not eligible for cleanup
This commit is contained in:
Mike McQuaid 2016-09-01 20:32:14 +01:00 committed by GitHub
commit a607a83749

View File

@ -1611,6 +1611,8 @@ class Formula
eligible_kegs.each do |keg|
if keg.linked?
opoo "Skipping (old) #{keg} due to it being linked"
elsif pinned? && keg == Keg.new(@pin.path.resolved_path)
opoo "Skipping (old) #{keg} due to it being pinned"
else
eligible_for_cleanup << keg
end