whimsical-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From s...@apache.org
Subject [whimsy] branch master updated: Extra spaces on skywalking page
Date Mon, 23 Mar 2020 09:50:36 GMT
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 82cdd4d  Extra spaces on skywalking page
82cdd4d is described below

commit 82cdd4dbfbf703ef8acdf952495fc6b646d82f42
Author: Sebb <sebb@apache.org>
AuthorDate: Mon Mar 23 09:49:52 2020 +0000

    Extra spaces on skywalking page
---
 tools/download_check.rb | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/tools/download_check.rb b/tools/download_check.rb
index a0ee8c7..30eb76b 100755
--- a/tools/download_check.rb
+++ b/tools/download_check.rb
@@ -260,7 +260,9 @@ ALIASES = {
 # Convert text reference to extension
 # e.g. SHA256 => sha256; [SIG] => asc
 def text2ext(txt)
-    tmp = txt.downcase.sub(%r{^\[(.+)\]$},'\1').sub('-','').sub(' checksum','').strip
+    # need to strip twice to handle ' [ asc ] '
+    # TODO: perhaps just remove all white-space?
+    tmp = txt.downcase.strip.sub(%r{^\[(.+)\]$},'\1').sub('-','').sub(' ?checksum','').strip
     ALIASES[tmp] || tmp
 end
 


Mime
View raw message