[calm - Cygwin server-side packaging maintenance script] branch master, updated. 20200611-17-gc86b22c

Jon TURNEY jturney@sourceware.org
Mon Nov 30 16:26:07 GMT 2020




https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/calm.git;h=c86b22cf040be188c30058c869fa15cac29a7367

commit c86b22cf040be188c30058c869fa15cac29a7367
Author: Jon Turney <jon.turney@dronecode.org.uk>
Date:   Sat Nov 28 13:51:32 2020 +0000

    Make homepage redirection warning less spamy
    
    Don't warn about intra-site redirects.


Diff:
---
 calm/fixes.py | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/calm/fixes.py b/calm/fixes.py
index 33c1087..063ebcd 100644
--- a/calm/fixes.py
+++ b/calm/fixes.py
@@ -133,7 +133,9 @@ def fix_homepage_src_hint(dirpath, hf, tf):
             logging.warning('homepage:%s permanently redirects to %s, fixing' % (homepage, redirect_homepage))
             homepage = redirect_homepage
         else:
-            logging.warning('homepage:%s permanently redirects to %s' % (homepage, redirect_homepage))
+            # don't warn about intra-site redirects
+            if not redirect_homepage.startswith(homepage):
+                logging.warning('homepage:%s permanently redirects to %s' % (homepage, redirect_homepage))
 
     # write updated hints
     if homepage != hints.get('homepage', None):



More information about the Cygwin-apps-cvs mailing list