#!/usr/bin/python # # Copyright (c) 2008-2017, The Tor Project, Inc. # See LICENSE for licensing information. # # Hi! # I'm redox.py, the Tor redocumentation tool! # I am a horrible hack! # I read the output of doxygen from stderr, and add missing DOCDOC comments # to tell you where documentation should go! # To use me, edit the stuff below... # ...and run 'make doxygen 2>doxygen.stderr' ... # ...and run ./scripts/maint/redox.py < doxygen.stderr ! # I'll make a bunch of new files by adding missing DOCDOC comments to your # source. Those files will have names like ./src/common/util.c.newdoc. # You will want to look over the changes by hand before checking them in. # # So, here's your workflow: # # 0. Make sure you're running a bourne shell for the redirects below. # 1. make doxygen 1>doxygen.stdout 2>doxygen.stderr. # 2. grep Warning doxygen.stderr | grep -v 'is not documented' | less # [This will tell you about all the bogus doxygen output you have] # 3. python ./scripts/maint/redox.py