[tor-commits] [arm/release] Interpretor help for POSTDESCRIPTOR

atagar at torproject.org atagar at torproject.org
Sun Sep 25 21:38:30 UTC 2011


commit 59768dee3ddeb3c69b2b617ec3939fb13d0677ad
Author: Damian Johnson <atagar at torproject.org>
Date:   Mon Sep 19 08:29:11 2011 -0700

    Interpretor help for POSTDESCRIPTOR
    
    Just basic usage information and a warning that, like LOADCONF, this isn't yet
    implemented.
---
 src/util/torInterpretor.py |    7 +++++--
 1 files changed, 5 insertions(+), 2 deletions(-)

diff --git a/src/util/torInterpretor.py b/src/util/torInterpretor.py
index e6b2e52..9c08f06 100644
--- a/src/util/torInterpretor.py
+++ b/src/util/torInterpretor.py
@@ -171,6 +171,8 @@ HELP_MAPADDRESS = """Replaces future requests for one address with another.
 Example:
   MAPADDRESS 0.0.0.0=torproject.org 1.2.3.4=tor.freehaven.net"""
 
+HELP_POSTDESCRIPTOR = """Simulates getting a new relay descriptor."""
+
 HELP_OPTIONS = {
   "HELP": ("/help [OPTION]", HELP_HELP),
   "WRITE": ("/write [PATH]", HELP_WRITE),
@@ -185,8 +187,9 @@ HELP_OPTIONS = {
   "SETEVENTS": ("SETEVENTS [EXTENDED] [EVENTS]", HELP_SETEVENTS),
   "USEFEATURE": ("USEFEATURE OPTION", HELP_USEFEATURE),
   "SAVECONF": ("SAVECONF", HELP_SAVECONF),
-  "LOADCONF": ("LOADCONF", HELP_LOADCONF),
+  "LOADCONF": ("LOADCONF...", HELP_LOADCONF),
   "MAPADDRESS": ("MAPADDRESS SOURCE_ADDR=DESTINATION_ADDR", HELP_MAPADDRESS),
+  "POSTDESCRIPTOR": ("POSTDESCRIPTOR [purpose=general/controller/bridge] [cache=yes/no]...", HELP_POSTDESCRIPTOR),
 }
 
 class InterpretorClosed(Exception):
@@ -496,7 +499,7 @@ class ControlInterpretor:
           featureOptions = torTools.getConn().getInfo("features/names")
           if featureOptions:
             outputEntry.append((featureOptions + "\n", OUTPUT_FORMAT))
-        elif arg in ("LOADCONF"):
+        elif arg in ("LOADCONF", "POSTDESCRIPTOR"):
           # gives a warning that this option isn't yet implemented
           outputEntry.append(("\n" + MULTILINE_UNIMPLEMENTED_NOTICE + "\n", ERROR_FORMAT))
       else:





More information about the tor-commits mailing list