2009-11-07 09:22:53 +03:00
|
|
|
===================================
|
2012-03-24 21:23:45 +04:00
|
|
|
Welcome to Zamboni's documentation!
|
2009-10-23 22:09:59 +04:00
|
|
|
===================================
|
|
|
|
|
2012-03-24 21:23:45 +04:00
|
|
|
Zamboni is the codebase for https://addons.mozilla.org/ and
|
2012-11-13 08:24:03 +04:00
|
|
|
https://marketplace.firefox.com/ ; the source lives at https://github.com/mozilla/zamboni
|
2009-10-23 22:09:59 +04:00
|
|
|
|
2012-03-24 21:23:45 +04:00
|
|
|
If you want to build a completely different site with all the same Django
|
|
|
|
optimizations for security, scalability, L10n, and ease of use, check out
|
|
|
|
Mozilla's `Playdoh starter kit <http://playdoh.readthedocs.org/>`_.
|
2009-12-23 07:58:18 +03:00
|
|
|
|
|
|
|
Installation
|
|
|
|
------------
|
2012-03-24 21:23:45 +04:00
|
|
|
What are you waiting for?! :ref:`Install Zamboni! <installation>`
|
2009-12-23 07:58:18 +03:00
|
|
|
|
|
|
|
|
|
|
|
Contents
|
|
|
|
--------
|
2009-10-23 22:09:59 +04:00
|
|
|
|
|
|
|
.. toctree::
|
2012-03-24 21:23:45 +04:00
|
|
|
:maxdepth: 2
|
2009-10-23 22:09:59 +04:00
|
|
|
|
2012-03-24 21:23:45 +04:00
|
|
|
topics/install-zamboni/index
|
|
|
|
topics/hacking/index
|
2009-12-23 07:58:18 +03:00
|
|
|
|
2012-03-24 21:23:45 +04:00
|
|
|
.. toctree::
|
|
|
|
:maxdepth: 2
|
|
|
|
:glob:
|
2009-12-23 07:58:18 +03:00
|
|
|
|
2012-03-24 21:23:45 +04:00
|
|
|
topics/*
|
2009-12-23 07:58:18 +03:00
|
|
|
|
2010-05-15 00:56:07 +04:00
|
|
|
gettext in Javascript
|
|
|
|
~~~~~~~~~~~~~~~~~~~~~
|
|
|
|
|
|
|
|
We have gettext in javascript! Just mark your strings with ``gettext()`` or
|
|
|
|
``ngettext()``. There isn't an ``_`` alias right now, since underscore.js has
|
|
|
|
that. If we end up with a lot of js translations, we can fix that. Check it
|
|
|
|
out::
|
|
|
|
|
|
|
|
cd locale
|
|
|
|
./extract-po.py -d javascript
|
|
|
|
pybabel init -l en_US -d . -i javascript.pot -D javascript
|
|
|
|
perl -pi -e 's/fuzzy//' en_US/LC_MESSAGES/javascript.po
|
|
|
|
pybabel compile -d . -D javascript
|
|
|
|
open http://0:8000/en-US/jsi18n/
|
|
|
|
|
2010-02-13 23:41:54 +03:00
|
|
|
Git Bisect
|
|
|
|
~~~~~~~~~~
|
|
|
|
|
|
|
|
Did you break something recently? Are you wondering which commit started the
|
|
|
|
problem? ::
|
2009-12-23 07:58:18 +03:00
|
|
|
|
2010-02-13 23:41:54 +03:00
|
|
|
git bisect start
|
|
|
|
git bisect bad
|
|
|
|
git bisect good <master> # Put the known-good commit here.
|
|
|
|
git bisect run fab test
|
|
|
|
git bisect reset
|
|
|
|
|
|
|
|
Git will churn for a while, running tests, and will eventually tell you where
|
|
|
|
you suck. See the git-bisect man page for more details.
|
|
|
|
|
|
|
|
|
|
|
|
Running Tests
|
|
|
|
~~~~~~~~~~~~~
|
2009-10-23 22:09:59 +04:00
|
|
|
|
2010-01-26 22:05:36 +03:00
|
|
|
* Run your tests like this::
|
|
|
|
|
|
|
|
python manage.py test --noinput --logging-clear-handlers
|
|
|
|
|
|
|
|
* ``--noinput`` tells Django not to ask about creating or destroying test
|
|
|
|
databases.
|
2012-06-01 08:42:29 +04:00
|
|
|
* ``--logging-clear-handlers`` tells nose that you don't want to see any
|
2010-01-26 22:05:36 +03:00
|
|
|
logging output. Without this, our debug logging will spew all over your
|
|
|
|
console during test runs. This can be useful for debugging, but it's not that
|
|
|
|
great most of the time. See the docs for more stuff you can do with
|
|
|
|
:mod:`nose and logging <nose.plugins.logcapture>`.
|
|
|
|
|
|
|
|
|
2010-02-13 23:41:54 +03:00
|
|
|
Building Docs
|
|
|
|
~~~~~~~~~~~~~
|
|
|
|
|
|
|
|
* If you're working on the docs, use ``make loop`` to keep your built pages
|
|
|
|
up-to-date.
|
|
|
|
|
|
|
|
|
2009-10-23 22:09:59 +04:00
|
|
|
Indices and tables
|
2009-11-07 09:22:53 +03:00
|
|
|
~~~~~~~~~~~~~~~~~~
|
2009-10-23 22:09:59 +04:00
|
|
|
|
|
|
|
* :ref:`genindex`
|
|
|
|
* :ref:`modindex`
|
|
|
|
* :ref:`search`
|