Add friendlier local file missing error
Closes Homebrew/homebrew#26481. Signed-off-by: Jack Nagel <jacknagel@gmail.com>
This commit is contained in:
parent
ccf37d5ac0
commit
ba8ef6a7ed
@ -113,7 +113,12 @@ class CurlDownloadStrategy < AbstractDownloadStrategy
|
||||
had_incomplete_download = false
|
||||
retry
|
||||
else
|
||||
raise CurlDownloadStrategyError, "Download failed: #{@url}"
|
||||
if @url =~ %r[^file://]
|
||||
msg = "File does not exist: #{@url.sub(%r[^file://], "")}"
|
||||
else
|
||||
msg = "Download failed: #{@url}"
|
||||
end
|
||||
raise CurlDownloadStrategyError, msg
|
||||
end
|
||||
end
|
||||
ignore_interrupts { temporary_path.rename(tarball_path) }
|
||||
|
Loading…
x
Reference in New Issue
Block a user