Hackage: Update page_url to avoid redirection

This commit is contained in:
Sam Ford 2020-12-13 16:21:28 -05:00
parent ced0da159f
commit 0ab449c577
No known key found for this signature in database
GPG Key ID: 95209E46C7FFDEFE

View File

@ -38,7 +38,7 @@ module Homebrew
/^(?<package_name>.+?)-\d+/i =~ File.basename(url)
# A page containing a directory listing of the latest source tarball
page_url = "https://hackage.haskell.org/package/#{package_name}/src"
page_url = "https://hackage.haskell.org/package/#{package_name}/src/"
# Example regex: `%r{<h3>example-(.*?)/?</h3>}i`
regex ||= %r{<h3>#{Regexp.escape(package_name)}-(.*?)/?</h3>}i