<?xml version='1.0' encoding='UTF-8'?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
  <id>https://www.ericholscher.com</id>
  <title>Eric Holscher - Posted in 2011</title>
  <updated>2026-04-20T04:45:54.044225+00:00</updated>
  <link href="https://www.ericholscher.com"/>
  <link href="https://www.ericholscher.com/blog/archive/2011/atom.xml" rel="self"/>
  <generator uri="https://ablog.readthedocs.io/" version="0.11.12">ABlog</generator>
  <entry>
    <id>https://www.ericholscher.com/blog/2011/apr/11/read-docs-update/</id>
    <title>Read the Docs Update</title>
    <updated>2011-04-11T19:22:37+00:00</updated>
    <content type="html">&lt;section id="read-the-docs-update"&gt;

&lt;p&gt;It’s been a while since I last talked about
&lt;a class="reference external" href="http://readthedocs.org"&gt;Read the Docs&lt;/a&gt;, and there has been a lot
of activity. This is an update on the latest and greatest new
features.&lt;/p&gt;
&lt;section id="psf-funding"&gt;
&lt;h2&gt;PSF Funding&lt;/h2&gt;
&lt;p&gt;The biggest news that has happened is that we have been given a
grant from the Python Software Foundation to help host the site.
Thanks PSF! They have
&lt;a class="reference external" href="http://pyfound.blogspot.com/2011/03/psf-funds-readthedocsorg.html"&gt;blogged about it&lt;/a&gt;,
and I am grateful that they have given us support. With the funds
they have offered, we have been able to make Read the Docs a lot
faster, and more robust. I will outline some of the changes below.&lt;/p&gt;
&lt;p&gt;This also means we won’t be going away any time soon!&lt;/p&gt;
&lt;/section&gt;
&lt;section id="new-theme"&gt;
&lt;h2&gt;New Theme&lt;/h2&gt;
&lt;aside class="system-message"&gt;
&lt;p class="system-message-title"&gt;System Message: INFO/1 (&lt;span class="docutils literal"&gt;/home/docs/checkouts/readthedocs.org/user_builds/ericholschercom/checkouts/latest/site/blog/2011/apr/11/read-docs-update.rst&lt;/span&gt;, line 4); &lt;em&gt;&lt;a href="#id1"&gt;backlink&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;Duplicate implicit target name: “new theme”.&lt;/p&gt;
&lt;/aside&gt;
&lt;p&gt;We have a fancy
&lt;a class="reference external" href="http://read-the-docs.readthedocs.org/en/latest/getting_started.html"&gt;new theme&lt;/a&gt;
for documentation on Read the Docs! If you have the ‘default’ theme
for your project, it will show up on the build of your docs on the
site. I think it is pretty great, thanks to the designers who spent
their time making it awesome. A really great feature is that the
&lt;strong&gt;new theme is mobile ready&lt;/strong&gt;. Go ahead and view a project using it
on your phone, or make your browser smaller and you will see the
fanciness. Having a custom theme will give us a base to build lots
of other neat features on top of.&lt;/p&gt;
&lt;/section&gt;
&lt;section id="better-architecture"&gt;
&lt;h2&gt;Better architecture&lt;/h2&gt;
&lt;p&gt;We had some connectivity trouble in between our servers a while
back, and this prompted me to make the site respond better to these
conditions. Every time you view documentation on a subdomain of
readthedocs.org, your request will never hit Django. So all of
these requests will work without a database. We have also added a
second application server with a load balance in front, which means
that one of the app servers could go away and your documentation
would still get served.&lt;/p&gt;
&lt;p&gt;That leaves our load balancer as the main single point of failure
at the moment. We’re using Varnish for the load balancer, and we’ve
implemented strong caching of data. Varnish will cache your docs
for up to a week, and it will be actively purged when you rebuild
your docs. This means that your docs will usually be served out of
memory, and without dependence on any other server but that one. We
have plans to elininate Varnish as a single POF, and then it would
only be our hosting provider that would be a single point of
failure (famous last words).&lt;/p&gt;
&lt;/section&gt;
&lt;section id="intersphinx-support"&gt;
&lt;h2&gt;Intersphinx support&lt;/h2&gt;
&lt;p&gt;&lt;a class="reference external" href="http://sphinx.readthedocs.org/en/latest/ext/intersphinx.html#sphinx.ext.intersphinx"&gt;Intersphinx&lt;/a&gt;
is an awesome feature of Sphinx that allows you to reference remote
sphinx documentation easily.
&lt;a class="reference external" href="http://read-the-docs.readthedocs.org/en/latest/features.html#intersphinx-support"&gt;RTD now supports it&lt;/a&gt;
for every project that we host.&lt;/p&gt;
&lt;/section&gt;
&lt;section id="improved-rtfd-org"&gt;
&lt;h2&gt;Improved rtfd.org&lt;/h2&gt;
&lt;p&gt;I’ve always had big ideas for rtfd.org, since it can act as a
short-url for things. &lt;em&gt;projectname&lt;/em&gt;.rtfd.org has always redirects
to the projects docs, but now we have something a lot better.
Inspired by Jacob Kaplan-Moss and his work on django.me, we now
support human-edited deep-linking within documentation hosted on
RTD.&lt;/p&gt;
&lt;p&gt;Taking another page from Jacob’s book, we seeded the index of our
projects with their Intersphinx data, so a lot of references will
automatically work. This works best with API reference docs, but
anything people have put links to in their documentation should
have been picked up. A couple of examples:&lt;/p&gt;
&lt;ul class="simple"&gt;
&lt;li&gt;&lt;p&gt;&lt;a class="reference external" href="http://pip.rtfd.org/git"&gt;http://pip.rtfd.org/git&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;a class="reference external" href="http://celery.rtfd.org/Task"&gt;http://celery.rtfd.org/Task&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;a class="reference external" href="http://sqlalchemy.rtfd.org/relationship"&gt;http://sqlalchemy.rtfd.org/relationship&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;If you go to a non-existent link on rtfd.org, you will be prompted
to enter a suggested URL. This will help build the data, and make
it more useful for everyone.&lt;/p&gt;
&lt;/section&gt;
&lt;section id="rtd-command-line-utility"&gt;
&lt;h2&gt;&lt;a class="reference external" href="https://github.com/ericholscher/rtd"&gt;rtd&lt;/a&gt; command line utility&lt;/h2&gt;
&lt;p&gt;RTD has had an
&lt;a class="reference external" href="http://read-the-docs.readthedocs.org/en/latest/api.html"&gt;API&lt;/a&gt;
for a while now, and with the addition of the support for rtfd.org,
I thought it would be neat to make it easier to access docs from
the command line. With a simple &lt;code class="docutils literal notranslate"&gt;&lt;span class="pre"&gt;pip&lt;/span&gt; &lt;span class="pre"&gt;install&lt;/span&gt; &lt;span class="pre"&gt;rtd&lt;/span&gt;&lt;/code&gt;, you will get
an rtd utility that will open docs on RTD. It supports 2 arguments,
the first being a project name, and the second being a slug to
append for the rtfd.org functionality. So like the example above:&lt;/p&gt;
&lt;div class="highlight-default notranslate"&gt;&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class="o"&gt;-&amp;gt;&lt;/span&gt; &lt;span class="n"&gt;rtd&lt;/span&gt; &lt;span class="n"&gt;pip&lt;/span&gt;
&lt;span class="n"&gt;Pip&lt;/span&gt; &lt;span class="n"&gt;Installs&lt;/span&gt; &lt;span class="n"&gt;Packages&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;
&lt;span class="n"&gt;Opening&lt;/span&gt; &lt;span class="n"&gt;browser&lt;/span&gt; &lt;span class="n"&gt;to&lt;/span&gt; &lt;span class="n"&gt;http&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="o"&gt;//&lt;/span&gt;&lt;span class="n"&gt;pip&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;rtfd&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;org&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;
&lt;span class="o"&gt;-&amp;gt;&lt;/span&gt; &lt;span class="n"&gt;rtd&lt;/span&gt; &lt;span class="n"&gt;celery&lt;/span&gt; &lt;span class="n"&gt;Task&lt;/span&gt;
&lt;span class="n"&gt;Distributed&lt;/span&gt; &lt;span class="n"&gt;task&lt;/span&gt; &lt;span class="n"&gt;queue&lt;/span&gt;
&lt;span class="n"&gt;Opening&lt;/span&gt; &lt;span class="n"&gt;browser&lt;/span&gt; &lt;span class="n"&gt;to&lt;/span&gt; &lt;span class="n"&gt;http&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="o"&gt;//&lt;/span&gt;&lt;span class="n"&gt;celery&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;rtfd&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;org&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="n"&gt;Task&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;It hits the RTD API to see if the project is on the site, and only
opens your browser if it doesn’t exist. I hope that in the future
we’ll make it easy to upload a project from the shell, and more.&lt;/p&gt;
&lt;/section&gt;
&lt;section id="more-docs"&gt;
&lt;h2&gt;More docs&lt;/h2&gt;
&lt;p&gt;Since we are a documentation site, we’ve always had documentation.
I’ve been adding more as time has gone on, and most of the features
I’ll be talking about today are
&lt;a class="reference external" href="http://read-the-docs.readthedocs.org/en/latest/features.html"&gt;already documented&lt;/a&gt;.
I also broke the documentation up into sections for users of the
site, and developers on the codebase, so it should be easier to
find for everyone to find what they are looking for.&lt;/p&gt;
&lt;/section&gt;
&lt;section id="conclusion"&gt;
&lt;h2&gt;Conclusion&lt;/h2&gt;
&lt;p&gt;I think that RTD can be doing a lot more to help out the community
with regards to documentation. I’ll write another post about that
soon. But if you are interested in helping out with the effort, all
of the code is
&lt;a class="reference external" href="https://github.com/rtfd/readthedocs.org"&gt;open source&lt;/a&gt; and we
love people to contribute. Feel free to jump in #readthedocs on
Freenode as well, if you have any questions or thoughts.&lt;/p&gt;
&lt;/section&gt;
&lt;/section&gt;
</content>
    <link href="https://www.ericholscher.com/blog/2011/apr/11/read-docs-update/"/>
    <summary>It’s been a while since I last talked about
Read the Docs, and there has been a lot
of activity. This is an update on the latest and greatest new
features.</summary>
    <published>2011-04-11T19:22:37+00:00</published>
  </entry>
  <entry>
    <id>https://www.ericholscher.com/blog/2011/jan/23/using-reviewboard-git/</id>
    <title>Using Reviewboard with Git</title>
    <updated>2011-01-23T21:25:40+00:00</updated>
    <content type="html">&lt;section id="using-reviewboard-with-git"&gt;

&lt;p&gt;&lt;a class="reference external" href="http://www.reviewboard.org/"&gt;Reviewboard&lt;/a&gt; is a great tool for
managing the process of Code Reviews. It has pretty good git
support, but it might not be obvious what the best way is to use
it. At work, I have a couple of different ways of pushing up code
for reviews, which I’ll talk about.&lt;/p&gt;
&lt;p&gt;This guide is assuming you are using your own bare repositories, on
the server hosting the Reviewboard instance. It’s mainly here so
that I can remember how to do this next time I need to. Also,
thanks to &lt;a class="reference external" href="http://traviscline.com/blog/"&gt;Travis Cline&lt;/a&gt; for the
initial pointers for this post.&lt;/p&gt;
&lt;section id="setting-up-reviewboard"&gt;
&lt;h2&gt;Setting up Reviewboard&lt;/h2&gt;
&lt;p&gt;Once you have Reviewboard installed, you need to add a Repository
in the admin, which is located at
&lt;code class="docutils literal notranslate"&gt;&lt;span class="pre"&gt;/admin/db/scmtools/repository/&lt;/span&gt;&lt;/code&gt;. The required fields have the
following values:&lt;/p&gt;
&lt;ul class="simple"&gt;
&lt;li&gt;&lt;p&gt;Name: The name of the project&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Hosting service: Custom&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Repository type: Git&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Path: The path to the local checkout of the git repository (ex.
/var/lib/git/name)&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Mirror Path: The &lt;strong&gt;Url&lt;/strong&gt; to the repository (ex.
&lt;a class="reference external" href="ssh://git&amp;#64;your.server.com/var/lib/git/name"&gt;ssh://git&amp;#64;your.server.com/var/lib/git/name&lt;/a&gt;)&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;The
&lt;a class="reference external" href="http://www.reviewboard.org/docs/manual/dev/admin/management/repositories/#git"&gt;Repository Documentation&lt;/a&gt;
has more about why you need this screwy configuration.&lt;/p&gt;
&lt;/section&gt;
&lt;section id="post-review"&gt;
&lt;h2&gt;post Review&lt;/h2&gt;
&lt;p&gt;Before we get started, you’re going to want to get the
&lt;a class="reference external" href="http://www.reviewboard.org/docs/manual/dev/users/tools/post-review/"&gt;post-review&lt;/a&gt;
tool that works along with Reviewboard. The easiest way to get it
is to &lt;code class="docutils literal notranslate"&gt;&lt;span class="pre"&gt;pip&lt;/span&gt; &lt;span class="pre"&gt;install&lt;/span&gt; &lt;span class="pre"&gt;RBTools&lt;/span&gt;&lt;/code&gt;.&lt;/p&gt;
&lt;/section&gt;
&lt;section id="pointing-to-the-right-reviewboard-instance"&gt;
&lt;h2&gt;Pointing to the right Reviewboard Instance&lt;/h2&gt;
&lt;p&gt;The easiest way to make sure your pointing at the right Reviewboard
instance is the &lt;em&gt;.reviewboardrc&lt;/em&gt; file in your home directory. You
only need to add one line to that file, which is:&lt;/p&gt;
&lt;div class="highlight-default notranslate"&gt;&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class="n"&gt;REVIEWBOARD_URL&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;&amp;quot;https://path.to.your.instance&amp;quot;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;If you are working with multiple instances that map to different
repos, you can set the Reviewboard instance for the specific repo
as well:&lt;/p&gt;
&lt;div class="highlight-default notranslate"&gt;&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class="n"&gt;git&lt;/span&gt; &lt;span class="n"&gt;config&lt;/span&gt; &lt;span class="n"&gt;reviewboard&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;url&lt;/span&gt; &lt;span class="n"&gt;https&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="o"&gt;//&lt;/span&gt;&lt;span class="n"&gt;path&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;to&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;your&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;instance&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;/section&gt;
&lt;section id="reviewing-a-branch"&gt;
&lt;h2&gt;Reviewing a Branch&lt;/h2&gt;
&lt;p&gt;Alright, now you are all setup to start posting reviews. The
easiest way to do that is to branch off of master, and start
committing. If you are following something similar to
&lt;a class="reference external" href="http://nvie.com/posts/a-successful-git-branching-model/"&gt;this awesome branching model&lt;/a&gt;,
this should be your normal workflow. Once your branch is ready to
be merged back into your project, you want to get it reviewed. You
can send a review equivalent to “this branch diffed against master”
like so:&lt;/p&gt;
&lt;div class="highlight-default notranslate"&gt;&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class="n"&gt;post&lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="n"&gt;review&lt;/span&gt; &lt;span class="o"&gt;--&lt;/span&gt;&lt;span class="n"&gt;guess&lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="n"&gt;summary&lt;/span&gt; &lt;span class="o"&gt;--&lt;/span&gt;&lt;span class="n"&gt;guess&lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="n"&gt;description&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;/section&gt;
&lt;section id="reviewing-one-commit"&gt;
&lt;h2&gt;Reviewing one commit&lt;/h2&gt;
&lt;p&gt;Another thing I find myself doing a lot is working on my master,
and only having one commit to review. In theory this should
probably be done on a bugfix branch, but such is life. There are
other good use cases for only reviewing the latest commit as well.
It’s done like so:&lt;/p&gt;
&lt;div class="highlight-default notranslate"&gt;&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class="n"&gt;post&lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="n"&gt;review&lt;/span&gt; &lt;span class="o"&gt;--&lt;/span&gt;&lt;span class="n"&gt;guess&lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="n"&gt;summary&lt;/span&gt; &lt;span class="o"&gt;--&lt;/span&gt;&lt;span class="n"&gt;guess&lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="n"&gt;description&lt;/span&gt; &lt;span class="o"&gt;--&lt;/span&gt;&lt;span class="n"&gt;parent&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="n"&gt;HEAD&lt;/span&gt;&lt;span class="o"&gt;^&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;/section&gt;
&lt;section id="reviewing-arbitrary-number-of-commits"&gt;
&lt;h2&gt;Reviewing arbitrary number of commits&lt;/h2&gt;
&lt;p&gt;It’s also possible to review any number of previous commits. It
looks a lot like the previous command:&lt;/p&gt;
&lt;div class="highlight-default notranslate"&gt;&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class="n"&gt;post&lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="n"&gt;review&lt;/span&gt; &lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="n"&gt;o&lt;/span&gt; &lt;span class="o"&gt;--&lt;/span&gt;&lt;span class="n"&gt;guess&lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="n"&gt;summary&lt;/span&gt; &lt;span class="o"&gt;--&lt;/span&gt;&lt;span class="n"&gt;guess&lt;/span&gt;&lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="n"&gt;description&lt;/span&gt; &lt;span class="o"&gt;--&lt;/span&gt;&lt;span class="n"&gt;parent&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="n"&gt;HEAD&lt;/span&gt;&lt;span class="o"&gt;~&lt;/span&gt;&lt;span class="mi"&gt;4&lt;/span&gt; &lt;span class="c1"&gt;#To review last 4 commits.&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;If you are familiar with git, you will understand that there is a
lot more that you can do with the –parent argument. I’ll leave the
possibilities up to your imagination.&lt;/p&gt;
&lt;/section&gt;
&lt;section id="other-useful-post-review-flags"&gt;
&lt;h2&gt;Other useful post-review flags&lt;/h2&gt;
&lt;p&gt;The are a couple of other useful post-review flags, that I use from
time to time.&lt;/p&gt;
&lt;ul class="simple"&gt;
&lt;li&gt;&lt;p&gt;-d This basically outputs all of the git commands that
post-review is using to generate the diffs. It’s a great way to
figure out what’s going wrong when it can’t find a diff.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;-o: This opens a web browser to the posted review once it’s
done. Great for easily making the review public.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;I hope this makes it a little easier for you to set up a git
repository with reviewboard.&lt;/p&gt;
&lt;/section&gt;
&lt;/section&gt;
</content>
    <link href="https://www.ericholscher.com/blog/2011/jan/23/using-reviewboard-git/"/>
    <summary>Reviewboard is a great tool for
managing the process of Code Reviews. It has pretty good git
support, but it might not be obvious what the best way is to use
it. At work, I have a couple of different ways of pushing up code
for reviews, which I’ll talk about.</summary>
    <published>2011-01-23T21:25:40+00:00</published>
  </entry>
  <entry>
    <id>https://www.ericholscher.com/blog/2011/jan/11/read-docs-updates/</id>
    <title>Read the Docs Updates</title>
    <updated>2011-01-11T02:00:00+00:00</updated>
    <content type="html">&lt;section id="read-the-docs-updates"&gt;

&lt;p&gt;Documentation writing will always be hard work. It’s a much
different mind-set than programming, and people that write good
code might not necessarily write good docs. However, this is a
known issue, and something that can’t really be solved.&lt;/p&gt;
&lt;p&gt;What you can do is make it easier to write documentation. Every
step along the way that you can give yourself an excuse to not
write documentation is another undocumented open source project.&lt;/p&gt;
&lt;p&gt;Luke Plant has a
&lt;a class="reference external" href="http://lukeplant.me.uk/blog/posts/docs-or-it-doesnt-exist/"&gt;great post&lt;/a&gt;
up about how important documentation is, and I completely agree. I
imagine a lot of the people using Django are using it because of
the documentation. I think as members of the Django community, we
need to build a culture of documentation within the greater Python
world. Python does tend to have better documentation than a lot of
languages, but it’s still not nearly what it could be.&lt;/p&gt;
&lt;p&gt;&lt;a class="reference external" href="http://readthedocs.org"&gt;Read the Docs&lt;/a&gt; exists to make it easier
to host your Sphinx documentation. Over the weekend,
&lt;a class="reference external" href="http://bobbygrace.info/"&gt;Bobby&lt;/a&gt;,
&lt;a class="reference external" href="https://github.com/ojii"&gt;Jonas&lt;/a&gt;, and I added a bunch of new
features to the site. I think it’s getting to the point where there
isn’t an easier or better way to host the documentation for your
Django project, and we’re only going to keep improving it!&lt;/p&gt;
&lt;p&gt;A different
&lt;a class="reference external" href="http://www.automation-excellence.com/team/eric-pierce"&gt;Eric&lt;/a&gt;
added a really nice
&lt;a class="reference external" href="http://readthedocs.org/docs/read-the-docs/latest/getting_started.html"&gt;Getting Started&lt;/a&gt;
guide for RTD, that shows how easy it is to get your projects
hosted with us.&lt;/p&gt;
&lt;p&gt;Anyway, on to the new features that we added.&lt;/p&gt;
&lt;section id="new-features"&gt;
&lt;h2&gt;New Features&lt;/h2&gt;
&lt;/section&gt;
&lt;section id="versions"&gt;
&lt;h2&gt;Versions&lt;/h2&gt;
&lt;p&gt;Versions of projects are easily one of the biggest requested
features on the site. For a long time we just supported building
the latest versions of your documentation. Now we support versions
of your documentation that are tagged in your VCS (hg/git only).&lt;/p&gt;
&lt;p&gt;A lot of larger projects need versioning because they support one
or two versions, as well as developing in the trunk. Django was the
main project we were thinking of, but some other projects have put
this to good use. A couple of examples are:&lt;/p&gt;
&lt;ul class="simple"&gt;
&lt;li&gt;&lt;p&gt;&lt;a class="reference external" href="http://readthedocs.org/docs/django/1.2.4/"&gt;Django’s latest stable build&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;a class="reference external" href="http://readthedocs.org/docs/fabric/0.9.3/"&gt;Fabric 0.9.3&lt;/a&gt;,&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;a class="reference external" href="http://django-admin-tools.readthedocs.org/"&gt;django-admin-tools’s awesome integration&lt;/a&gt;
that has all it’s versions hosted with us.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/section&gt;
&lt;section id="pdf-support"&gt;
&lt;h2&gt;PDF Support&lt;/h2&gt;
&lt;p&gt;Sphinx has interesting support for PDF generation through Latex. In
my testing it was pretty unreliable, but I was able to rangle it
into working well enough to expose in the UI. So now almost every
project will have a “Download PDF” button. This code has version
support as well, so we can offer PDFs of certain versions.&lt;/p&gt;
&lt;ul class="simple"&gt;
&lt;li&gt;&lt;p&gt;&lt;a class="reference external" href="http://media.readthedocs.org/pdf/django/latest/django.pdf"&gt;Django’s trunk documentation PDF&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;a class="reference external" href="http://media.readthedocs.org/pdf/django-cms/2.1.0.rc2/django-cms.pdf"&gt;Django CMS 2.1.0-rc2 PDF&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;a class="reference external" href="http://media.readthedocs.org/pdf/varnish/latest/varnish.pdf"&gt;Varnish trunk PDF&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Another interesting part of this feature is that this building code
has been abstracted out, so we can support epub, plain text, and
all the other Sphinx output formats that people want.&lt;/p&gt;
&lt;/section&gt;
&lt;section id="badges-on-the-project-pages"&gt;
&lt;h2&gt;Badges on the project pages&lt;/h2&gt;
&lt;p&gt;We killed the RTD header on hosted documentation pages in favor of
a Badge in the lower right hand corner. The header clashed with a
lot of the themes, and the badge is nice because it gives us a
place to put functionality that is always visible, but is obviously
not part of the hosted documentation. We want to build some more
functionality into the badge, like switching between versions and
linking back to the project’s RTD page, once we build a good UI for
it.&lt;/p&gt;
&lt;/section&gt;
&lt;section id="sponsorship"&gt;
&lt;h2&gt;Sponsorship&lt;/h2&gt;
&lt;p&gt;&lt;a class="reference external" href="http://www.revsys.com/"&gt;Revsys&lt;/a&gt; has agreed to sponsor the
hosting costs for RTD. Jacob Kaplan-Moss has always been a big
proponent of documentation, and I’m glad that he and Frank Wiles
are helping us keep Read the Docs around and get better. We tried
to make the sponsorship subtle and not intrusive, so please let me
know if it bothers you and we can try and figure something out.&lt;/p&gt;
&lt;/section&gt;
&lt;section id="conclusion"&gt;
&lt;h2&gt;Conclusion&lt;/h2&gt;
&lt;p&gt;I think that these features are really starting to make RTD a
compelling platform for hosting your documentation. We are planning
more awesome features that will make RTD even better. I’m really
excited about the project and I hope that you either host your docs
with us, or find docs that we host useful.&lt;/p&gt;
&lt;/section&gt;
&lt;/section&gt;
</content>
    <link href="https://www.ericholscher.com/blog/2011/jan/11/read-docs-updates/"/>
    <summary>Documentation writing will always be hard work. It’s a much
different mind-set than programming, and people that write good
code might not necessarily write good docs. However, this is a
known issue, and something that can’t really be solved.</summary>
    <published>2011-01-11T02:00:00+00:00</published>
  </entry>
  <entry>
    <id>https://www.ericholscher.com/blog/2011/jan/10/handling-django-settings-files/</id>
    <title>Handling Django Settings Files</title>
    <updated>2011-01-10T19:09:27+00:00</updated>
    <content type="html">&lt;section id="handling-django-settings-files"&gt;

&lt;p&gt;I have seen a lot of talk over the past couple years about how to
handle different settings files and databases, synced between
production and development. I have happened onto a way of doing it
that makes me happy, and figured I would share it with the world.&lt;/p&gt;
&lt;section id="file-structure"&gt;
&lt;h2&gt;File structure&lt;/h2&gt;
&lt;p&gt;I use a file structure that looks like this:&lt;/p&gt;
&lt;div class="highlight-default notranslate"&gt;&lt;div class="highlight"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class="n"&gt;project&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;
    &lt;span class="n"&gt;settings&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;
        &lt;span class="fm"&gt;__init__&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;py&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;empty&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
        &lt;span class="n"&gt;base&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;py&lt;/span&gt;
        &lt;span class="n"&gt;sqlite&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;py&lt;/span&gt;
        &lt;span class="n"&gt;postgres&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;py&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;The base.py contains all of the configuration options that are
shared among the databases. INSTALLED_APPS, etc. All of the
DATABASE settings should be specified in the more-specific files.
As well as things that differ by environment, like remote servers,
cache settings, cookie domains, and other things.&lt;/p&gt;
&lt;p&gt;This allows you to run the sqlite settings file, and have it be set
to localhost, or whatever your development settings are. Then in
production you just run against the postgres settings.&lt;/p&gt;
&lt;p&gt;A good example of this being used in practice is on
&lt;a class="reference external" href="https://github.com/rtfd/readthedocs.org/tree/master/settings"&gt;Read the Docs&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;But wait, there’s more!&lt;/strong&gt;&lt;/p&gt;
&lt;/section&gt;
&lt;section id="manage-py-for-dev"&gt;
&lt;h2&gt;manage.py for dev&lt;/h2&gt;
&lt;p&gt;./manage.py is great for development. It is the easiest way to get
started, and it automatically sets up your paths and stuff. With my
setup, I actually
&lt;a class="reference external" href="https://github.com/rtfd/readthedocs.org/blob/master/manage.py#L3"&gt;explicitly set&lt;/a&gt;
manage.py’s settings file to the sqlite file.&lt;/p&gt;
&lt;p&gt;This means that whenever you are using manage.py, you are in a
development context. So, what do you do about production?&lt;/p&gt;
&lt;/section&gt;
&lt;section id="django-admin-py-is-for-production"&gt;
&lt;h2&gt;django-admin.py is for production&lt;/h2&gt;
&lt;p&gt;In production, you set your DJANGO_SETTINGS_MODULE to the
postgres settings file. So whenever you use django-admin.py, you
will be running against the production database.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;I really like this scheme, because it gives you a logical distinction between production and development in your code, and in your interface on the CLI.&lt;/strong&gt;
When you are developing, you are using manage.py and editing the
sqlite settings file. The reverse for production.&lt;/p&gt;
&lt;/section&gt;
&lt;/section&gt;
</content>
    <link href="https://www.ericholscher.com/blog/2011/jan/10/handling-django-settings-files/"/>
    <summary>I have seen a lot of talk over the past couple years about how to
handle different settings files and databases, synced between
production and development. I have happened onto a way of doing it
that makes me happy, and figured I would share it with the world.</summary>
    <published>2011-01-10T19:09:27+00:00</published>
  </entry>
</feed>
