|
@@ -2,6 +2,8 @@
|
|
|
How is Django Formed?
|
|
|
=====================
|
|
|
|
|
|
+.. highlight:: console
|
|
|
+
|
|
|
This document explains how to release Django.
|
|
|
|
|
|
**Please, keep these instructions up-to-date if you make changes!** The point
|
|
@@ -54,9 +56,7 @@ You'll need a few things before getting started:
|
|
|
``you@example.com`` is the email address associated with the key you want to
|
|
|
use.
|
|
|
|
|
|
-* An install of some required Python packages:
|
|
|
-
|
|
|
- .. code-block:: bash
|
|
|
+* An install of some required Python packages::
|
|
|
|
|
|
$ pip install wheel twine
|
|
|
|
|
@@ -117,7 +117,7 @@ any time leading up to the actual release:
|
|
|
rather than the releaser, but here are the steps. Provided you have an
|
|
|
account on Transifex::
|
|
|
|
|
|
- python scripts/manage_translations.py fetch
|
|
|
+ $ python scripts/manage_translations.py fetch
|
|
|
|
|
|
and then commit the changed/added files (both .po and .mo). Sometimes there
|
|
|
are validation errors which need to be debugged, so avoid doing this task
|
|
@@ -148,16 +148,16 @@ OK, this is the fun part, where we actually push out a release!
|
|
|
#. A release always begins from a release branch, so you should make sure
|
|
|
you're on a stable branch and up-to-date. For example::
|
|
|
|
|
|
- git checkout stable/1.5.x
|
|
|
- git pull
|
|
|
+ $ git checkout stable/1.5.x
|
|
|
+ $ git pull
|
|
|
|
|
|
#. If this is a security release, merge the appropriate patches from
|
|
|
``django-private``. Rebase these patches as necessary to make each one a
|
|
|
simple commit on the release branch rather than a merge commit. To ensure
|
|
|
this, merge them with the ``--ff-only`` flag; for example::
|
|
|
|
|
|
- git checkout stable/1.5.x
|
|
|
- git merge --ff-only security/1.5.x
|
|
|
+ $ git checkout stable/1.5.x
|
|
|
+ $ git merge --ff-only security/1.5.x
|
|
|
|
|
|
(This assumes ``security/1.5.x`` is a branch in the ``django-private`` repo
|
|
|
containing the necessary security patches for the next release in the 1.5
|
|
@@ -193,7 +193,7 @@ OK, this is the fun part, where we actually push out a release!
|
|
|
|
|
|
#. Tag the release using ``git tag``. For example::
|
|
|
|
|
|
- git tag --sign --message="Tag 1.5.1" 1.5.1
|
|
|
+ $ git tag --sign --message="Tag 1.5.1" 1.5.1
|
|
|
|
|
|
You can check your work by running ``git tag --verify <tag>``.
|
|
|
|
|
@@ -205,9 +205,7 @@ OK, this is the fun part, where we actually push out a release!
|
|
|
create the release packages in a ``dist/`` directory. Note that we don't
|
|
|
publish wheel files for 1.4.
|
|
|
|
|
|
-#. Generate the hashes of the release packages:
|
|
|
-
|
|
|
- .. code-block:: bash
|
|
|
+#. Generate the hashes of the release packages::
|
|
|
|
|
|
$ cd dist
|
|
|
$ md5sum *
|
|
@@ -217,7 +215,9 @@ OK, this is the fun part, where we actually push out a release!
|
|
|
#. Create a "checksums" file, ``Django-<<VERSION>>.checksum.txt`` containing
|
|
|
the hashes and release information. Start with this template and insert the
|
|
|
correct version, date, GPG key ID (from
|
|
|
- ``gpg --list-keys --keyid-format LONG``), release URL, and checksums::
|
|
|
+ ``gpg --list-keys --keyid-format LONG``), release URL, and checksums:
|
|
|
+
|
|
|
+ .. code-block:: text
|
|
|
|
|
|
This file contains MD5, SHA1, and SHA256 checksums for the source-code
|
|
|
tarball of Django <<VERSION>>, released <<DATE>>.
|
|
@@ -276,22 +276,16 @@ Making the release(s) available to the public
|
|
|
Now you're ready to actually put the release out there. To do this:
|
|
|
|
|
|
#. Upload the release package(s) to the djangoproject server, replacing
|
|
|
- A.B. with the appropriate version number, e.g. 1.5 for a 1.5.x release:
|
|
|
-
|
|
|
- .. code-block:: bash
|
|
|
+ A.B. with the appropriate version number, e.g. 1.5 for a 1.5.x release::
|
|
|
|
|
|
$ scp Django-* djangoproject.com:/home/www/www/media/releases/A.B
|
|
|
|
|
|
-#. Upload the checksum file(s):
|
|
|
-
|
|
|
- .. code-block:: bash
|
|
|
+#. Upload the checksum file(s)::
|
|
|
|
|
|
$ scp Django-A.B.C.checksum.txt.asc djangoproject.com:/home/www/www/media/pgp/Django-A.B.C.checksum.txt
|
|
|
|
|
|
#. Test that the release packages install correctly using ``easy_install``
|
|
|
- and ``pip``. Here's one method (which requires `virtualenvwrapper`__):
|
|
|
-
|
|
|
- .. code-block:: bash
|
|
|
+ and ``pip``. Here's one method (which requires `virtualenvwrapper`__)::
|
|
|
|
|
|
$ RELEASE_VERSION='1.7.2'
|
|
|
$ MAJOR_VERSION=`echo $RELEASE_VERSION| cut -c 1-3`
|
|
@@ -318,9 +312,7 @@ Now you're ready to actually put the release out there. To do this:
|
|
|
correct (proper version numbers, no stray ``.pyc`` or other undesirable
|
|
|
files).
|
|
|
|
|
|
-#. Upload the release packages to PyPI:
|
|
|
-
|
|
|
- .. code-block:: bash
|
|
|
+#. Upload the release packages to PyPI::
|
|
|
|
|
|
$ twine upload -s dist/*
|
|
|
|
|
@@ -334,7 +326,7 @@ Now you're ready to actually put the release out there. To do this:
|
|
|
#. Make the blog post announcing the release live.
|
|
|
|
|
|
#. For a new version release (e.g. 1.5, 1.6), update the default stable version
|
|
|
- of the docs by flipping the ``is_default`` flag to ``True`` on the
|
|
|
+ of the docs by flipping the ``is_default`` flag to `deployment/wsgi/uwsgi.html`True`` on the
|
|
|
appropriate ``DocumentRelease`` object in the ``docs.djangoproject.com``
|
|
|
database (this will automatically flip it to ``False`` for all
|
|
|
others); you can do this using the site's admin.
|