[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[or-cvs] r11243: Add a perl script to regenerate proposal 000-index.txt so th (in tor/trunk: . doc/spec/proposals)



Author: nickm
Date: 2007-08-21 03:24:31 -0400 (Tue, 21 Aug 2007)
New Revision: 11243

Added:
   tor/trunk/doc/spec/proposals/reindex.pl
Modified:
   tor/trunk/
   tor/trunk/doc/spec/proposals/000-index.txt
Log:
 r14764@catbus:  nickm | 2007-08-21 03:23:12 -0400
 Add a perl script to regenerate proposal 000-index.txt so that it always matches the statuses and titles in the other proposals, and so that it has a sorted-by-status section.



Property changes on: tor/trunk
___________________________________________________________________
 svk:merge ticket from /tor/trunk [r14764] on 8246c3cf-6607-4228-993b-4d95d33730f1

Modified: tor/trunk/doc/spec/proposals/000-index.txt
===================================================================
--- tor/trunk/doc/spec/proposals/000-index.txt	2007-08-21 07:24:29 UTC (rev 11242)
+++ tor/trunk/doc/spec/proposals/000-index.txt	2007-08-21 07:24:31 UTC (rev 11243)
@@ -12,6 +12,10 @@
 
    This is an informational document.
 
+   Everything in this document below the line of '=' signs is automatically
+   generated by reindex.pl; do not edit by hand.
+
+============================================================
 Proposals by number:
 
 000  Index of Tor Proposals [META]
@@ -30,12 +34,48 @@
 109  No more than one server per IP address [CLOSED]
 110  Avoiding infinite length circuits [OPEN]
 111  Prioritizing local traffic over relayed traffic [OPEN]
-112  Bring Back Pathlen Coin Weight [OPEN]
+112  Bring Back Pathlen Coin Weight [SUPERSEDED]
 113  Simplifying directory authority administration [OPEN]
 114  Distributed Storage for Tor Hidden Service Descriptors [OPEN]
 115  Two Hop Paths [OPEN]
 116  Two hop paths from entry guards [OPEN]
 117  IPv6 exits [OPEN]
-118  Advertising multiple ORPorts at once [RESEARCH]
+118  Advertising multiple ORPorts at once [NEEDS-RESEARCH]
 119  New PROTOCOLINFO command for controllers [CLOSED]
 120  Suicide descriptors when Tor servers stop [OPEN]
+
+
+Proposals by status:
+
+ OPEN:
+   105  Version negotiation for the Tor protocol
+   110  Avoiding infinite length circuits
+   111  Prioritizing local traffic over relayed traffic
+   113  Simplifying directory authority administration
+   114  Distributed Storage for Tor Hidden Service Descriptors
+   115  Two Hop Paths
+   116  Two hop paths from entry guards
+   117  IPv6 exits
+   120  Suicide descriptors when Tor servers stop
+ ACCEPTED:
+   101  Voting on the Tor Directory System
+   103  Splitting identity key from regularly used signing key
+   104  Long and Short Router Descriptors
+ NEEDS-RESEARCH:
+   118  Advertising multiple ORPorts at once
+ META:
+   000  Index of Tor Proposals
+   001  The Tor Proposal Process
+   098  Proposals that should be written
+   099  Miscellaneous proposals
+ CLOSED:
+   102  Dropping "opt" from the directory format
+   106  Checking fewer things during TLS handshakes
+   107  Uptime Sanity Checking
+   108  Base "Stable" Flag on Mean Time Between Failures
+   109  No more than one server per IP address
+   119  New PROTOCOLINFO command for controllers
+ SUPERSEDED:
+   112  Bring Back Pathlen Coin Weight
+ DEAD:
+   100  Tor Unreliable Datagram Extension Proposal

Added: tor/trunk/doc/spec/proposals/reindex.pl
===================================================================
--- tor/trunk/doc/spec/proposals/reindex.pl	                        (rev 0)
+++ tor/trunk/doc/spec/proposals/reindex.pl	2007-08-21 07:24:31 UTC (rev 11243)
@@ -0,0 +1,71 @@
+#!/usr/bin/perl -w
+# Copyright 2007 Nick Mathewson.  See LICENSE for licensing information.
+
+use strict;
+
+my $propdir = ".";
+local *DIR;
+local *F;
+
+opendir(DIR, $propdir) || die "Can't open $propdir";
+my @files = sort grep { /^\d\d\d-.*[^\~]$/ } readdir(DIR);
+closedir DIR;
+
+my %title = ();
+my %status = ();
+
+my @KNOWN_STATUSES = qw{
+    OPEN ACCEPTED NEEDS-RESEARCH META CLOSED SUPERSEDED DEAD};
+
+for my $f (@files) {
+    my $num = substr($f, 0, 3);
+    my $status = undef;
+    my $title = undef;
+    open(F, "$f");
+    while (<F>) {
+	last if (/^\s*$/);
+	if (/^Status: (.*)/) {
+	    $status = uc $1;
+	    chomp $status;
+	}
+	if (/^Title: (.*)/) {
+	    $title = $1;
+	    $title =~ s/\.$//;
+	    chomp $title;
+	}
+    }
+    close F;
+    die "I've never heard of status $status in proposal $num"
+	unless (grep(/$status/, @KNOWN_STATUSES) == 1);
+    die "Proposal $num has a bad status line" if (!defined $status);
+    die "Proposal $num has a bad title line" if (!defined $title);
+    $title{$num} = $title;
+    $status{$num} = $status;
+}
+
+local *OUT;
+open(OUT, ">000-index.txt.tmp");
+
+open(F, "000-index.txt") or die "Can't open index file.";
+while (<F>) {
+    print OUT;
+    last if (/^={3,}/);
+}
+close(F);
+
+print OUT "Proposals by number:\n\n";
+
+for my $num (sort keys %title) {
+    print OUT "$num  $title{$num} [$status{$num}]\n";
+}
+
+print OUT "\n\nProposals by status:\n\n";
+for my $status (@KNOWN_STATUSES) {
+    print OUT " $status:\n";
+    for my $num (sort keys %status) {
+	next unless ($status{$num} eq $status);
+	print OUT "   $num  $title{$num}\n";
+    }
+}
+
+rename('000-index.txt.tmp', '000-index.txt');


Property changes on: tor/trunk/doc/spec/proposals/reindex.pl
___________________________________________________________________
Name: svn:executable
   + *