commit 3266f04925b871519f3193890edb5c40f4be0b39 Author: Nick Mathewson nickm@torproject.org Date: Mon Apr 28 12:07:57 2014 -0400
Fix the check-docs script
We broke it when we added anchors to the manpage.
This patch fixes it, and makes it sorta detect missing anchors. --- doc/tor.1.txt | 8 ++++---- scripts/maint/checkOptionDocs.pl | 5 +++-- 2 files changed, 7 insertions(+), 6 deletions(-)
diff --git a/doc/tor.1.txt b/doc/tor.1.txt index 79368f5..302547e 100644 --- a/doc/tor.1.txt +++ b/doc/tor.1.txt @@ -491,15 +491,15 @@ GENERAL OPTIONS attacker who obtains the logs. If only one severity level is given, all messages of that level or higher will be sent to the listed destination.
-**Log** __minSeverity__[-__maxSeverity__] **file** __FILENAME__:: +[[Log2]] **Log** __minSeverity__[-__maxSeverity__] **file** __FILENAME__:: As above, but send log messages to the listed filename. The "Log" option may appear more than once in a configuration file. Messages are sent to all the logs that match their severity level.
-**Log** **[**__domain__,...**]**__minSeverity__[-__maxSeverity__] ... **file** __FILENAME__ + +[[Log3]] **Log** **[**__domain__,...**]**__minSeverity__[-__maxSeverity__] ... **file** __FILENAME__ +
-**Log** **[**__domain__,...**]**__minSeverity__[-__maxSeverity__] ... **stderr**|**stdout**|**syslog**:: +[[Log4]] **Log** **[**__domain__,...**]**__minSeverity__[-__maxSeverity__] ... **stderr**|**stdout**|**syslog**:: As above, but select messages by range of log severity __and__ by a set of "logging domains". Each logging domain corresponds to an area of functionality inside Tor. You can specify any number of severity ranges @@ -2197,7 +2197,7 @@ The following options are used for running a testing Tor network. Try this often to download a v3 authority certificate before giving up. Changing this requires that **TestingTorNetwork** is set. (Default: 8)
-**TestingDirAuthVoteGuard** __node__,__node__,__...__:: +[[TestingDirAuthVoteGuard]] **TestingDirAuthVoteGuard** __node__,__node__,__...__:: A list of identity fingerprints, nicknames, country codes and address patterns of nodes to vote Guard for regardless of their uptime and bandwidth. See the **ExcludeNodes** option for more diff --git a/scripts/maint/checkOptionDocs.pl b/scripts/maint/checkOptionDocs.pl index 23e57b4..94307c6 100755 --- a/scripts/maint/checkOptionDocs.pl +++ b/scripts/maint/checkOptionDocs.pl @@ -41,8 +41,9 @@ loadTorrc("./src/config/torrc.sample.in", %torrcSampleOptions); my $considerNextLine = 0; open(F, "./doc/tor.1.txt") or die; while (<F>) { - if (m!^**([A-Za-z0-9_]+)**!) { - $manPageOptions{$1} = 1; + if (m!^(?:[[([A-za-z0-9_]+)]] *)?**([A-Za-z0-9_]+)**!) { + $manPageOptions{$2} = 1; + print "Missing an anchor: $2\n" unless (defined $1 or $2 eq 'tor'); } } close F;
tor-commits@lists.torproject.org