Update symlink even if cached_location already exists.
This commit is contained in:
parent
9edc355052
commit
b63ac557bc
@ -297,9 +297,10 @@ class CurlDownloadStrategy < AbstractFileDownloadStrategy
|
|||||||
ignore_interrupts do
|
ignore_interrupts do
|
||||||
temporary_path.rename(cached_location)
|
temporary_path.rename(cached_location)
|
||||||
symlink_location.dirname.mkpath
|
symlink_location.dirname.mkpath
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
FileUtils.ln_s cached_location.relative_path_from(symlink_location.dirname), symlink_location, force: true
|
FileUtils.ln_s cached_location.relative_path_from(symlink_location.dirname), symlink_location, force: true
|
||||||
end
|
|
||||||
end
|
|
||||||
rescue CurlDownloadStrategyError
|
rescue CurlDownloadStrategyError
|
||||||
raise if urls.empty?
|
raise if urls.empty?
|
||||||
puts "Trying a mirror..."
|
puts "Trying a mirror..."
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user