[88843] users/ryandesign/scripts/badpyports

ryandesign at macports.org ryandesign at macports.org
Fri Jan 13 02:13:07 PST 2012


Revision: 88843
          http://trac.macports.org/changeset/88843
Author:   ryandesign at macports.org
Date:     2012-01-13 02:13:05 -0800 (Fri, 13 Jan 2012)
Log Message:
-----------
badpyports: also find livecheck problems

Modified Paths:
--------------
    users/ryandesign/scripts/badpyports

Modified: users/ryandesign/scripts/badpyports
===================================================================
--- users/ryandesign/scripts/badpyports	2012-01-13 10:03:56 UTC (rev 88842)
+++ users/ryandesign/scripts/badpyports	2012-01-13 10:13:05 UTC (rev 88843)
@@ -12,6 +12,7 @@
 DEPENDENCYPROBLEMS=0
 DEFAULTVERSIONPROBLEMS=0
 DOCDIRPROBLEMS=0
+LIVECHECKPROBLEMS=0
 for NAME in $NAMES; do
     STUBPORT=py-$NAME
     STUBFILE="$(port file $STUBPORT)"
@@ -40,9 +41,14 @@
         DOCDIRPROBLEMS=$(($DOCDIRPROBLEMS + 1))
         PROBLEMPORTS="$PROBLEMPORTS $STUBPORT"
     fi
+    if [ -z "$(grep -E 'livecheck\.type[[:space:]]+none' "$STUBFILE")" ]; then
+        printf "%s enables livecheck even in the subports\n" $STUBPORT
+        LIVECHECKPROBLEMS=$(($LIVECHECKPROBLEMS + 1))
+        PROBLEMPORTS="$PROBLEMPORTS $STUBPORT"
+    fi
 done
 
-TOTALPROBLEMS=$(($DEPENDENCYPROBLEMS + $DEFAULTVERSIONPROBLEMS + $DOCDIRPROBLEMS))
+TOTALPROBLEMS=$(($DEPENDENCYPROBLEMS + $DEFAULTVERSIONPROBLEMS + $DOCDIRPROBLEMS + $LIVECHECKPROBLEMS))
 
 echo
 printf "Out of %d ports using the unified python portgroup, there are %d problems.\n" $TOTALPYPORTS $TOTALPROBLEMS
@@ -65,6 +71,13 @@
     echo "should be installed into \${prefix}/share/doc/\${subport} rather than \${prefix}/share/doc/\${name}."
 fi
 
+if [ $LIVECHECKPROBLEMS -gt 0 ]; then
+    echo
+    printf "%d ports have livecheck problems. Livecheck should only be enabled in the stub port.\n" $LIVECHECKPROBLEMS
+    echo "Livecheck directives should be enclosed in an \"if {\${name} == \${subport}}\" block;"
+    echo "in the \"else\" part, set livecheck.type to none."
+fi
+
 if [ $TOTALPROBLEMS -gt 0 ]; then
     echo
     echo "The maintainers of these ports are:"
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20120113/669ec548/attachment.html>


More information about the macports-changes mailing list