Skip to content

Commit

Permalink
[FIXED JENKINS-24329] Update Go crawler to handle download site changes.
Browse files Browse the repository at this point in the history
The download page now provides direct, absolute URLs and we're now more lenient
about picking up links from the page, as the filename regex will handle things.
  • Loading branch information
orrc committed Aug 19, 2014
1 parent 4334bff commit 5933fb9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions golang.groovy
Expand Up @@ -21,8 +21,8 @@ webClient.setJavaScriptEnabled(false);

// Fetch URLs in order from latest...
HtmlPage latest = webClient.getPage(latestUrl)
latest.selectNodes("//td/a[starts-with(@href, '/dl/')]").each { HtmlAnchor e ->
urls << e.getHrefAttribute().replace("/dl/", "https://storage.googleapis.com/golang/")
latest.selectNodes("//td/a").each { HtmlAnchor e ->
urls << e.getHrefAttribute()
}

// ..to oldest
Expand Down

0 comments on commit 5933fb9

Please sign in to comment.