website: fix download parsing

This commit is contained in:
Mitchell Hashimoto 2013-07-16 11:42:11 -07:00
parent ce995d77a4
commit f9db6b3227
1 changed files with 2 additions and 1 deletions

View File

@ -17,7 +17,8 @@ if !ENV["PACKER_DISABLE_DOWNLOAD_FETCH"]
response = http.request(req)
response.body.split("\n").each do |line|
next if line !~ /\/mitchellh\/packer\/(#{ENV["PACKER_VERSION"]}.+?)\?/
next if line !~ /\/mitchellh\/packer\/(#{Regexp.quote(ENV["PACKER_VERSION"])}.+?)'/
p $1.to_s
filename = $1.to_s
os = filename.split("_")[1]
next if os == "SHA256SUMS"