<div class="gmail_quote">On Mon, Jul 27, 2009 at 11:18 AM, David Bern <span dir="ltr">&lt;<a href="mailto:odie5533@gmail.com">odie5533@gmail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div class="im">On Fri, Jul 24, 2009 at 12:22 PM, Andrew Francis&lt;<a href="mailto:andrewfr_ice@yahoo.com">andrewfr_ice@yahoo.com</a>&gt; wrote:<br></div></blockquote><div> </div><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div class="im"> Can do. Tell me how to submit a document patch.<br></div></blockquote><div><br>David, thanks for trying to answer, but you described a few of the particulars in a slightly non-standard way and you skipped a few steps.<br>
<br>The process for editing code and submitting patches is documented in detail here: <a href="http://twistedmatrix.com/trac/wiki/TwistedDevelopment">http://twistedmatrix.com/trac/wiki/TwistedDevelopment</a><br> <br>I&#39;ll attach a few additional notes on editing docs.<br>
<br></div><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><div class="im"></div>&lt;<a href="http://twistedmatrix.com/trac/browser/trunk/doc/core/howto/choosing-reactor.xhtml" target="_blank">http://twistedmatrix.com/trac/browser/trunk/doc/core/howto/choosing-reactor.xhtml</a>&gt;<br>

and at the bottom is a download link<br>
&lt;<a href="http://twistedmatrix.com/trac/browser/trunk/doc/core/howto/choosing-reactor.xhtml?format=raw" target="_blank">http://twistedmatrix.com/trac/browser/trunk/doc/core/howto/choosing-reactor.xhtml?format=raw</a>&gt;.</blockquote>
<div><br>Instead of doing a diff on a single document like this — it&#39;s very hard
to test to make sure that you can actually generate the docs that way —
you should make a checkout of Twisted, like this:<br>
<div style="margin-left: 40px;">
<pre class="wiki">svn checkout svn://<a href="http://svn.twistedmatrix.com/svn/Twisted/trunk">svn.twistedmatrix.com/svn/Twisted/trunk</a> ~/my-code-dir/Twisted/trunk</pre>
</div>
This ensures you have the most up-to-date copy of Twisted.  You only have to download it once; in the future you can just do<br>
<pre style="margin-left: 40px;" class="wiki">cd ~/my-code-dir/Twisted/trunk<br>svn update<br></pre>

Then, edit the document (or documents) that you want to change under
doc/.  In order to make sure your changes are complete and correct, as
well as to preview what they will look like on the website, you need to
run &#39;lore&#39; on them.  In this specific case, you can do<br>
<pre style="margin-left: 40px;" class="wiki">cd ~/my-code-dir/Twisted/trunk/doc/core/howto<br>lore choosing-reactor.xhtml<br></pre>

Then you can look at &quot;choosing-reactor.html&quot; (notice the input is &quot;.xhtml&quot; and the output is &quot;.html&quot;) in the web browser of your choice.<br><br>Please note that lore is rather picky.  You <i>can&#39;t</i> do &#39;lore my-code-dir/Twisted/.../howto/choosing-reactor.xhtml&#39; unless you know how to set up lore&#39;s environment properly; it looks for certain things in its current directory which are only present in the &#39;howto&#39; directory.<br>
<br></div><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">Make a backup of the document, modify it to your liking, then at a<br>
console run<br>
&gt;diff -u choosing-reactor_orig.xhtml choosing-reactor.xhtml &gt; choosing-reactor.patch</blockquote><div><br>In order to streamline the process of getting the diff accepted, please diff it from the root of the repository.  In the case of more complex patches, this helps to avoid forgetting to include things; it also allows the reviewer to apply your patch more easily without inspecting it or manually specifying all the names of the files to be patched.  Given the directory structure I described above, this would be:<br>
<pre style="margin-left: 40px;" class="wiki">cd ~/my-code-dir/Twisted/trunk<br>svn diff &gt; choosing-reactor.patch<br></pre>
Then submit the patch for review as described above.<br><br>Thanks a lot for your interest in contributing!<br></div></div>