289163ebca26 initial-docs

docs: write a basic overview document
[view raw] [browse files]
author Steve Losh <steve@stevelosh.com>
date Mon, 14 Jun 2010 23:22:33 -0400
parents cadaa12baca9
children cf64f6f74ad3
branches/tags initial-docs
files docs/hgreview/static/review.css docs/hgreview/static/review.less docs/overview.rst

Changes

--- a/docs/hgreview/static/review.css	Mon Jun 14 22:44:19 2010 -0400
+++ b/docs/hgreview/static/review.css	Mon Jun 14 23:22:33 2010 -0400
@@ -1,34 +1,146 @@
 @import url("aal.css");
 body, html {
-  background-color: #fcfcfc;
+  background-color: #f8f7e8;
   font-family: Georgia, serif;
-  color: #111;
+  color: #222;
 }
-h1, h2 {
-  font-weight: normal;
-}
-h1 {
-  letter-spacing: 1px;
-}
-a {
+body a, html a {
   color: #b6410c;
   text-decoration: none;
 }
-a:hover {
-  text-decoration: none;
+body a:hover, html a:hover {
+  text-decoration: underline;
+}
+body a.headerlink, html a.headerlink {
+  display: none;
 }
-.document .sphinxsidebar {
-  float: left;
+body h1,
+html h1,
+body h2,
+html h2,
+body h3,
+html h3,
+body h4,
+html h4,
+body h5,
+html h5,
+body h6,
+html h6 {
+  font-weight: normal;
+}
+body h1, html h1 {
+  letter-spacing: 1px;
+}
+body ul, html ul {
+  list-style-type: none;
+}
+body ul li, html ul li {
+  margin-left: 0;
+}
+body ul li li, html ul li li {
+  margin-left: 1em;
 }
 .related {
   display: none;
 }
-.bodywrapper {
+.document {
+  -webkit-border-radius: 8px;
+  -moz-border-radius: 8px;
+  border-radius: 8px;
+  border: 1px solid #edecc7;
+  margin: 25px auto 0px;
+  padding: 0px 00px;
+  width: 800px;
+}
+.document .documentwrapper {
+  -webkit-border-radius: 8px;
+  -moz-border-radius: 8px;
+  border-radius: 8px;
+  background-color: #fbfbf3;
   float: left;
+  width: 100%;
+}
+.document .documentwrapper .bodywrapper {
+  -webkit-border-radius: 8px;
+  -moz-border-radius: 8px;
+  border-radius: 8px;
+  background-color: #fefefe;
+  margin-left: 230px;
+  border-left: 1px solid #edecc7;
+  padding: 20px 30px;
+  min-height: 700px;
+}
+.document .documentwrapper .bodywrapper div pre {
+  border: 1px solid #edecc7;
+  background-color: #fbfbf3;
+  font-size: 13px;
+  font-family: Monaco, Consolas, "Courier New", monospace;
+  line-height: 24px;
+  margin-bottom: 32px;
+  margin-top: -8px;
+  margin-left: 24px;
+  padding: 0px 8px;
+  width: 498px;
+  overflow-x: auto;
 }
-.document {
-  margin: 30px auto 0px;
+.document .documentwrapper .bodywrapper span.pre {
+  background-color: #fafaef;
+  border: 1px solid #edecc7;
+  padding: 0px 6px;
+  font-size: 13px;
+  font-family: Monaco, Consolas, "Courier New", monospace;
+  line-height: 24px;
+  white-space: pre;
+}
+.document .documentwrapper .bodywrapper ul span.pre {
+  background-color: inherit;
+  border: none;
+  padding: 0;
+}
+.document .documentwrapper .bodywrapper a em {
+  font-style: normal;
+}
+.document .documentwrapper .bodywrapper tt.docutils.literal {
+  background-color: #fafaef;
+  border: 1px solid #edecc7;
+  padding: 0px 6px;
+  font-size: 13px;
+  font-family: Monaco, Consolas, "Courier New", monospace;
+  line-height: 24px;
+  white-space: pre;
+}
+.document .documentwrapper .bodywrapper tt.docutils.literal span.pre {
+  border: 0;
+  padding: 0;
+}
+.document .sphinxsidebar {
+  float: left;
+  margin-left: -100%;
+  width: 210px;
+  padding: 20px 20px;
+}
+.document .sphinxsidebar #searchbox h3 {
+  margin-bottom: 8px;
+}
+.document .sphinxsidebar #searchbox form input:nth-child(1) {
+  border: 1px solid #999;
+  font-size: 16px;
+}
+.document .sphinxsidebar #searchbox form input:nth-child(2) {
+  display: block;
+  margin-top: 6px;
+  width: 60px;
+}
+.document .sphinxsidebar #searchbox .searchtip {
+  display: none;
 }
 .clearer {
   clear: both;
 }
+.footer {
+  width: 800px;
+  margin: 8px auto 40px;
+  padding-right: 10px;
+  text-align: right;
+  font-style: italic;
+}
--- a/docs/hgreview/static/review.less	Mon Jun 14 22:44:19 2010 -0400
+++ b/docs/hgreview/static/review.less	Mon Jun 14 23:22:33 2010 -0400
@@ -42,7 +42,7 @@
             margin-left: 0;
 
             li {
-                margin-left: 2em;
+                margin-left: 1em;
             }
         }
     }
@@ -69,6 +69,7 @@
             margin-left: 230px;
             border-left: 1px solid @c-cream;
             padding: 20px 30px;
+            min-height: 700px;
 
             div pre {
                 border: 1px solid @c-cream;
@@ -90,6 +91,7 @@
                 font-size: 13px;
                 font-family: @font-mono;
                 line-height: 24px;
+                white-space: pre;
             }
             ul {
                 span.pre {
@@ -101,12 +103,26 @@
             a em {
                 font-style: normal;
             }
+            tt.docutils.literal {
+                background-color: lighten(@c-soft-cream, 2%);
+                border: 1px solid @c-cream;
+                padding: 0px 6px;
+                font-size: 13px;
+                font-family: @font-mono;
+                line-height: 24px;
+                white-space: pre;
+
+                span.pre {
+                    border: 0;
+                    padding: 0;
+                }
+            }
         }
     }
     .sphinxsidebar {
         float: left;
         margin-left: -100%;
-        width: 220px;
+        width: 210px;
         padding: 20px 20px;
 
         #searchbox {
--- a/docs/overview.rst	Mon Jun 14 22:44:19 2010 -0400
+++ b/docs/overview.rst	Mon Jun 14 23:22:33 2010 -0400
@@ -1,9 +1,89 @@
 Overview
 ========
 
+Let's get started using hg-review.  No matter how you want to use it, you need
+to install it first!
 
 Installation
 ------------
 
+hg-review requires `Python <http://python.org>`_ 2.5 or later and `Mercurial
+<http://hg-scm.org>`_ 1.4 or later
+
+You probably have both of these requirements already, but if you encounter
+problems you might want to check these first with ``python --version`` and
+``hg --version``.
+
+hg-review also depends on a couple of other things like `Flask
+<http://flask.pocoo.org>`_ and `Jinja2 <http://jinja.pocoo.org/2/>`_, but it
+bundles these requirements so you don't need to worry about them.
+
+To install hg-review, first clone the extension somewhere::
+
+    hg clone http://bitbucket.org/sjl/hg-review/
+
+Then add it to your ``~/.hgrc`` file::
+
+    [extensions]
+    review = [path to]/hg-review/review/
+
 Usage
 -----
+
+The easiest way to work with hg-review is with the :doc:`web interface
+</webui>`.  There's also a command-line interface, but it's really easiest to
+work with the web ui.
+
+Projects with Existing Code Reviews
+'''''''''''''''''''''''''''''''''''
+
+If you want to work with a repository that already has code review set up, all
+you need to do is cd into that repository, run ``hg review --init`` to pull
+down the review data, and then run ``hg review --web`` to fire up the web ui.
+
+Once that's done you can visit http://localhost:8080/ in your browser to start
+reviewing.
+
+You should read over the :doc:`concepts </concepts>` documentation to make sure
+you know how hg-review works, and the :doc:`web interface </webui>`
+documentation for a quick tour of how to use the web ui.
+
+Projects without Existing Code Reviews
+''''''''''''''''''''''''''''''''''''''
+
+If you want to *start* using hg-review with a repository, you need to do a few
+things to get it ready.
+
+First, create a repository to hold the code review data. This repository should
+be in a location that's accessible by anyone that needs to see the review data.
+
+For example, if you're working on an open-source project that's hosted at
+http://bitbucket.org/you/project/ you should create a new repository for
+the review data at http://bitbucket.org/you/project-review/
+
+Next you'll need to initialize the review data in your project. ``cd`` into you
+project's directory and run:: 
+
+    hg review --init --remote-path URL
+
+The ``URL`` should be the URL of the review repo you just created.
+
+This will create a local review data repo for you, as well as an ``.hgreview``
+file in your project. You need to commit this ``.hgreview`` file to your
+project with the command that hg-review suggested.
+
+Don't worry, this is the only time hg-review will make you commit something to
+your project's repository and clutter up its changelog.
+
+Now you can get to work reviewing changesets with the web interface by
+running ``hg review --web`` in your project.
+
+You should read over the :doc:`concepts </concepts>` documentation to make sure
+you know how hg-review works, and the :doc:`web interface </webui>`
+documentation for a quick tour of how to use the web ui.
+
+Reporting Bugs
+--------------
+
+If you encounter any errors while using hg-review please `post a bug
+<http://bitbucket.org/sjl/hg-review/issues/>`_.