Remove the direct url writer from Resource

This commit is contained in:
Jack Nagel 2015-01-08 14:18:41 -05:00
parent ba8926ea11
commit 0f01e9ff43
3 changed files with 3 additions and 3 deletions

View File

@ -161,7 +161,7 @@ end
class LegacyPatch < ExternalPatch class LegacyPatch < ExternalPatch
def initialize(strip, url) def initialize(strip, url)
super(strip) super(strip)
resource.url = url resource.url(url)
resource.download_strategy = CurlDownloadStrategy resource.download_strategy = CurlDownloadStrategy
end end

View File

@ -9,7 +9,7 @@ class Resource
include FileUtils include FileUtils
attr_reader :checksum, :mirrors, :specs, :using attr_reader :checksum, :mirrors, :specs, :using
attr_writer :url, :checksum, :version attr_writer :checksum, :version
attr_accessor :download_strategy attr_accessor :download_strategy
# Formula name must be set after the DSL, as we have no access to the # Formula name must be set after the DSL, as we have no access to the

View File

@ -224,7 +224,7 @@ class Bottle
checksum, tag = spec.checksum_for(bottle_tag) checksum, tag = spec.checksum_for(bottle_tag)
filename = Filename.create(formula, tag, spec.revision) filename = Filename.create(formula, tag, spec.revision)
@resource.url = build_url(spec.root_url, filename) @resource.url(build_url(spec.root_url, filename))
@resource.download_strategy = CurlBottleDownloadStrategy @resource.download_strategy = CurlBottleDownloadStrategy
@resource.version = formula.pkg_version @resource.version = formula.pkg_version
@resource.checksum = checksum @resource.checksum = checksum