639e837f240c

cli: add help for --web
[view raw] [browse files]
author Steve Losh <steve@stevelosh.com>
date Mon, 05 Jul 2010 22:55:35 -0400
parents 26b710ccba73
children 11a7e1d494d2 a6499117bd1a
branches/tags (none)
files review/cli.py review/helps.py

Changes

--- a/review/cli.py	Mon Jul 05 21:56:20 2010 -0400
+++ b/review/cli.py	Mon Jul 05 22:55:35 2010 -0400
@@ -350,6 +350,7 @@
     - hg help review-comment
     - hg help review-signoff
     - hg help review-check
+    - hg help review-web
 
     Once you've reviewed some changesets don't forget to push your comments and
     signoffs so other people can view them.
@@ -414,6 +415,7 @@
     (['review-comment'], ('Adding code review comments for changesets'), (helps.COMMENT)),
     (['review-signoff'], ('Adding code review signoffs for changesets'), (helps.SIGNOFF)),
     (['review-check'], ('Checking the review status of changesets'), (helps.CHECK)),
+    (['review-web'], ('Using the web interface to review changesets'), (helps.WEB)),
 )
 
 colortable = {
--- a/review/helps.py	Mon Jul 05 21:56:20 2010 -0400
+++ b/review/helps.py	Mon Jul 05 22:55:35 2010 -0400
@@ -124,3 +124,30 @@
   that a signoff of "no" will make this test succeed.
 
 """
+
+WEB = r"""
+USAGE: hg review --web [--read-only] [--allow-anon] [--address ADDRESS] [--port PORT]
+
+Start the web interface on the given address and port.
+
+Visit http://localhost:8080/ (replace the port number if you specified
+a different port) in a modern browser of your choice to use the web interface.
+
+If ``--read-only`` is given the interface will be read-only: comments,
+signoffs, pushes and pulls will be disabled. This is useful when you want to
+show the data to someone but do not want them to be able to add data in your
+name.
+
+If ``--allow-anon`` is given users of the web interface will be able to add
+comments even if ``--read-only`` is given. The username for these comments will
+be set to an anonymous username.
+
+If ``--address`` is given the web interface will listen on the given address
+instead of the default ``127.0.0.1``. It can be useful to specify ``0.0.0.0``
+when you want to allow another machine to view the interface, but **be
+careful** because this will allow other people to add comments and signoffs in
+your name unless you use the ``--read-only`` and/or ``--allow-anon`` options.
+
+If ``--port`` is given the web interface will listen on the given port.
+
+"""