From a4ea89157165e2a1ad5b750f9ba826a2c33e1e02 Mon Sep 17 00:00:00 2001 From: Robert Muir Date: Mon, 10 Sep 2012 19:00:45 +0000 Subject: [PATCH] add level=none option so we can find more broken html in solr javadocs git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1383047 13f79535-47bb-0310-9956-ffa450edef68 --- dev-tools/scripts/checkJavaDocs.py | 10 +++++----- solr/build.xml | 2 ++ 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/dev-tools/scripts/checkJavaDocs.py b/dev-tools/scripts/checkJavaDocs.py index 7c9244cc427..c9aabcb68c5 100644 --- a/dev-tools/scripts/checkJavaDocs.py +++ b/dev-tools/scripts/checkJavaDocs.py @@ -302,8 +302,8 @@ def checkPackageSummaries(root, level='class'): True if there are problems. """ - if level != 'class' and level != 'package' and level != 'method': - print('unsupported level: %s, must be "class" or "package" or "method"' % level) + if level != 'class' and level != 'package' and level != 'method' and level != 'none': + print('unsupported level: %s, must be "class" or "package" or "method" or "none"' % level) sys.exit(1) #for dirPath, dirNames, fileNames in os.walk('%s/lucene/build/docs/api' % root): @@ -329,7 +329,7 @@ def checkPackageSummaries(root, level='class'): continue if 'package-summary.html' in fileNames: - if level != 'package' and checkSummary('%s/package-summary.html' % dirPath): + if (level == 'class' or level == 'method') and checkSummary('%s/package-summary.html' % dirPath): anyMissing = True for fileName in fileNames: fullPath = '%s/%s' % (dirPath, fileName) @@ -342,14 +342,14 @@ def checkPackageSummaries(root, level='class'): anyMissing = True if 'overview-summary.html' in fileNames: - if checkSummary('%s/overview-summary.html' % dirPath): + if level != 'none' and checkSummary('%s/overview-summary.html' % dirPath): anyMissing = True return anyMissing if __name__ == '__main__': if len(sys.argv) < 2 or len(sys.argv) > 3: - print('usage: %s [class|package|method]' % sys.argv[0]) + print('usage: %s [none|package|class|method]' % sys.argv[0]) sys.exit(1) if len(sys.argv) == 2: level = 'class' diff --git a/solr/build.xml b/solr/build.xml index 1f939b4d1a1..29953ff1b18 100644 --- a/solr/build.xml +++ b/solr/build.xml @@ -551,6 +551,8 @@ + +