You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@whimsical.apache.org by se...@apache.org on 2020/12/06 14:46:08 UTC

[whimsy] branch master updated: Must have '-' before version; don't save archives

This is an automated email from the ASF dual-hosted git repository.

sebb pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/whimsy.git


The following commit(s) were added to refs/heads/master by this push:
     new e3d4f4a  Must have '-' before version; don't save archives
e3d4f4a is described below

commit e3d4f4a6f41a73866037ded51e97d03e23e24b1e
Author: Sebb <se...@apache.org>
AuthorDate: Sun Dec 6 14:45:59 2020 +0000

    Must have '-' before version; don't save archives
---
 tools/download_check.rb | 12 +++++++-----
 1 file changed, 7 insertions(+), 5 deletions(-)

diff --git a/tools/download_check.rb b/tools/download_check.rb
index b2936c6..2bf33e0 100755
--- a/tools/download_check.rb
+++ b/tools/download_check.rb
@@ -440,12 +440,14 @@ def _checkDownloadPage(path, tlp, version)
             W "Already seen link for #{base}"
         else
             ext = $2 # save for use after RE match
-            if base[0..-(ext.size+2)] =~ %r{^(.+?)(\d.+)$}
-              $versions[$2][$1.chomp('-')] << ext
-            else
-              W "Cannot parse #{base} for version"
-            end
             $vercheck[base] = [h =~ %r{^https?://archive.apache.org/} ? 'archive' : (h =~ %r{https?://repo\d?\.maven\.org/} ? 'maven' : 'live')]
+            unless $vercheck[base].first == 'archive'
+              if base[0..-(ext.size+2)] =~ %r{^(.+?)-(\d.+)$}
+                $versions[$2][$1] << ext
+              else
+                W "Cannot parse #{base} for version"
+              end
+            end
         end
         # Text must include a '.' (So we don't check 'Source')
         if t.include?('.') and not base == File.basename(t.strip.downcase)