diff --git a/Documentation/Cookbook/Scripts/otb_warnings.py b/Documentation/Cookbook/Scripts/otb_warnings.py index 1d1b549d4f550d8cef3fe9e8dba4938ba7c340b0..93bf8d0f20cd48129ea5244bd010be62720b2958 100644 --- a/Documentation/Cookbook/Scripts/otb_warnings.py +++ b/Documentation/Cookbook/Scripts/otb_warnings.py @@ -1,4 +1,5 @@ import sys +import re def parameter_warnings(app_warn, app, key): @@ -17,11 +18,13 @@ def parameter_warnings(app_warn, app, key): if "." in name: warn("name contains a special character (.)") + # disabled because there are so many for now #if description == "": #warn("missing description") - if len(description) > 0 and description[-1] != ".": - warn("description does not end with a period") + # disabled because there are so many for now + #if len(description) > 0 and description[-1] != ".": + #warn("description does not end with a period") if len(description) > 0 and " :" in description: warn("description has a space before a colon") @@ -38,7 +41,7 @@ def application_documentation_warnings(app): if not longdescription[-1] == ".": warn("Application Long Description does not end with a period (.)") - if "\n " in longdescription: + if re.search("\\n [a-zA-Z]", longdescription): warn("Application Long Description contains '\\n ' pattern (usually not intended)") if " :" in longdescription: