From: heister Date: Fri, 24 Jan 2014 23:18:58 +0000 (+0000) Subject: add script to check doxygen formatting X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=21041d29ae1ec85c291ca29f79a2c5ef5c793a1a;p=dealii-svn.git add script to check doxygen formatting git-svn-id: https://svn.dealii.org/trunk@32307 0785d39b-7218-0410-832d-ea1e28bc413d --- diff --git a/tests/scripts/checkdoxygen.py b/tests/scripts/checkdoxygen.py new file mode 100755 index 0000000000..3bcd7f5da3 --- /dev/null +++ b/tests/scripts/checkdoxygen.py @@ -0,0 +1,30 @@ +#!/usr/bin/python + +# run this script on all headers of deal.II to check that +# all doxygen groups have matching @{ @} pairs. +# for example: +# find include -name "*h" -print | xargs -n 1 ../tests/scripts/checkdoxygen.py + +import sys + +args=sys.argv +args.pop(0) + +f = open(args[0]) +lines = f.readlines() +f.close() + + +count = 0 +lineno = 1 +for l in lines: + if "@{" in l: + count = count + 1 + elif "@}" in l: + count = count -1 + if (count < 0): + sys.exit("Error in file '%s' in line %d"%(args[0],lineno)); + lineno = lineno + 1 + +if (count != 0): + sys.exit("Error: missing closing braces in file '%s'"%(args[0]));