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: Show server type response
Date Wed, 05 Oct 2016 10:21:52 GMT
This is an automated email from the ASF dual-hosted git repository.

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

The following commit(s) were added to refs/heads/master by this push:
       new  a0ee475   Show server type response
a0ee475 is described below

commit a0ee4756777418e228de3b6d04108f1dff94e13c
Author: Sebb <sebb@apache.org>
AuthorDate: Wed Oct 5 11:21:43 2016 +0100

    Show server type response
---
 tools/mirror_check.rb | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/tools/mirror_check.rb b/tools/mirror_check.rb
index ff1c609..aadfcd1 100755
--- a/tools/mirror_check.rb
+++ b/tools/mirror_check.rb
@@ -213,6 +213,9 @@ def checkHTTP(base)
 
   setup
 
+  response = getHTTPHdrs(base)
+  I "Server: #{response['server']}"
+
   # Check the mirror time (and that zzz/ is readable)
   time = check_page(base, 'zzz/time.txt', severity = :F)
   if time
@@ -341,8 +344,8 @@ end
 
 if __FILE__ == $0
   init
-  url = ARGV[0] || DEFAULT
-  checkHTTP(url)
+  url = ARGV[0] || abort("Need URL to test!")
+  checkHTTP(url+"") # allow url to be untainted later
   # display the test results
   @tests.each { |t| t.map{|k, v| puts "#{k}: - #{v}"}} 
   if @fails > 0

-- 
To stop receiving notification emails like this one, please contact
['"commits@whimsical.apache.org" <commits@whimsical.apache.org>'].

Mime
View raw message