mirror of
https://github.com/Homebrew/brew.git
synced 2025-07-14 16:09:03 +08:00
keg: tweak retry comment.
This commit is contained in:
parent
53fe6b518f
commit
e01fa7d2ae
@ -647,13 +647,10 @@ class Keg
|
|||||||
dst.delete if options[:overwrite] && (dst.exist? || dst.symlink?)
|
dst.delete if options[:overwrite] && (dst.exist? || dst.symlink?)
|
||||||
dst.make_relative_symlink(src)
|
dst.make_relative_symlink(src)
|
||||||
rescue Errno::EEXIST => e
|
rescue Errno::EEXIST => e
|
||||||
# We're linking a different version of the same formula
|
# Retry if we're linking a different version of the same
|
||||||
# Note that the AlreadyLinkedError check above *should*
|
# formula. The `AlreadyLinkedError` above won't catch
|
||||||
# have caught this, but there are circumstances in which
|
# this if a formula is missing an optlink. In that case,
|
||||||
# we end up with symlinks for a formula even though
|
# delete the symlink and retry.
|
||||||
# it seems to be missing an optlink. In that case,
|
|
||||||
# we should be clear to blow those away and replace
|
|
||||||
# them.
|
|
||||||
if dst.symlink? && Keg.for(dst).name == name
|
if dst.symlink? && Keg.for(dst).name == name
|
||||||
dst.unlink
|
dst.unlink
|
||||||
retry
|
retry
|
||||||
|
Loading…
x
Reference in New Issue
Block a user