Date: prev next · Thread: first prev next last
2010 Archives by date, by thread · List index


Hi,

I'm attaching a patch that adds a script to the scratch directory of a
build repo that tries to find undocumented classes using doxygen. It's
meant to be invoked in a subdirectory of the source code, so in case one
is familiar with Calc, she can run it under sc/ and add doxygen comments
to the classes she know, etc.

I'm intentionally not using 'make docs', because the target here is to
allow quick iteration, ie. to run 'find-undocumented-classes.sh -q' in a
subdirectory, add a few comments, run again, etc.

Does the idea sounds sane, OK to push?

Thanks.
From 0fd0d400e3a64cb9619a207868c835d18acce162 Mon Sep 17 00:00:00 2001
From: Miklos Vajna <vmiklos@frugalware.org>
Date: Mon, 22 Nov 2010 14:33:57 +0100
Subject: [PATCH] Add script to find undocumented classes

---
 scratch/find-undocumented-classes.sh |   26 ++++++++++++++++++++++++++
 1 files changed, 26 insertions(+), 0 deletions(-)
 create mode 100755 scratch/find-undocumented-classes.sh

diff --git a/scratch/find-undocumented-classes.sh b/scratch/find-undocumented-classes.sh
new file mode 100755
index 0000000..58a133b
--- /dev/null
+++ b/scratch/find-undocumented-classes.sh
@@ -0,0 +1,26 @@
+#!/bin/bash
+
+# finds undocumented classes in the current directory (recursive)
+
+filter=
+quiet=n
+if [ "$1" = "-q" ]; then
+    filter=">/dev/null"
+    quiet=y
+fi
+
+doxygen=$(mktemp -d)
+eval doxygen -g $doxygen/doxygen.cfg $filter
+sed -i "/HTML_OUTPUT/s|html|$doxygen/html|" $doxygen/doxygen.cfg
+sed -i '/GENERATE_LATEX/s/= YES/= NO/' $doxygen/doxygen.cfg
+sed -i '/RECURSIVE/s/= NO/= YES/' $doxygen/doxygen.cfg
+eval doxygen $doxygen/doxygen.cfg $filter 2> $doxygen/errors.txt
+if [ "$quiet" == "n" ]; then
+    echo
+    echo "The following classes are undocumented:"
+    echo
+fi
+cat $doxygen/errors.txt|grep 'Warning: Compound.*is not documented'
+rm -rf $doxygen
+
+# vim:set shiftwidth=4 softtabstop=4 expandtab:
-- 
1.7.3.2

Attachment: pgpAo5IGkGVRP.pgp
Description: PGP signature


Context


Privacy Policy | Impressum (Legal Info) | Copyright information: Unless otherwise specified, all text and images on this website are licensed under the Creative Commons Attribution-Share Alike 3.0 License. This does not include the source code of LibreOffice, which is licensed under the Mozilla Public License (MPLv2). "LibreOffice" and "The Document Foundation" are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy.