Browse files

Fixed #3902 -- Added some excellent notes about installing Django on …

…Windows. Thanks,

git-svn-id: bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
1 parent 99d12c5 commit 518bc15b218d1fc971757b6d72decc2576cd9b53 @malcolmt malcolmt committed Sep 14, 2007
Showing with 43 additions and 18 deletions.
  1. +43 −18 docs/install.txt
61 docs/install.txt
@@ -127,51 +127,76 @@ Installing an official release
1. Download the latest release from our `download page`_.
- 2. Untar the downloaded file (e.g. ``tar xzvf Django-NNN.tar.gz``).
+ 2. Untar the downloaded file (e.g. ``tar xzvf Django-NNN.tar.gz``,
+ where ``NNN`` is the version number of the latest release).
+ If you are a Windows user, you can download the command-line tool
+ bsdtar_ to do this, or you can use a GUI-based tool such as 7-zip_.
- 3. Change into the downloaded directory (e.g. ``cd Django-NNN``).
+ 3. Change into the directory created in step 2 (e.g. ``cd Django-NNN``).
- 4. Run ``sudo python install``.
+ 4. If you are using Linux, Mac OSX or some other flavour of Unix, enter
+ the command``sudo python install`` at the shell prompt.
+ If you are using Windows, start up a command shell with administrator
+ privileges and run the command `` install``.
-The command will install Django in your Python installation's ``site-packages``
+These commands will install Django in your Python installation's
+``site-packages`` directory.
.. _distribution specific notes: ../distributions/
+.. _bsdtar:
+.. _7-zip:
Installing the development version
If you'd like to be able to update your Django code occasionally with the
latest bug fixes and improvements, follow these instructions:
-1. Make sure you have Subversion_ installed.
-2. Check out the Django code into your Python ``site-packages`` directory.
+1. Make sure that you have Subversion_ installed, and that you can run its
+ commands from a shell. (Enter ``svn help`` at a shell prompt to test
+ this.)
- On Linux / Mac OSX / Unix, do this::
+2. Check out Django's main development branch (the 'trunk') like so::
- svn co django_src
- ln -s `pwd`/django_src/django SITE-PACKAGES-DIR/django
+ svn co django-trunk
+3. Next, you need to make sure that the Python interpreter can load Django's
+ code. There are various ways of accomplishing this. One of the most
+ convenient, on Linux, Mac OSX or other Unix-like systems, is to use a
+ symbolic link::
+ ln -s `pwd`/django-trunk/django SITE-PACKAGES-DIR/django
(In the above line, change ``SITE-PACKAGES-DIR`` to match the location of
your system's ``site-packages`` directory, as explained in the
"Where are my ``site-packages`` stored?" section above.)
- On Windows, do this::
+ Alternatively, you can define your ``PYTHONPATH`` environment variable
+ so that it includes the ``django`` subdirectory of ``django-trunk``.
+ This is perhaps the most convenient solution on Windows systems, which
+ don't support symbolic links. (Environment variables can be defined on
+ Windows systems `from the Control Panel`_.)
+ .. admonition:: What about Apache and mod_python?
- svn co c:\Python24\lib\site-packages\django
+ If you are using Apache and mod_python rather than Django's
+ development server, then instead of defining the ``PYTHONPATH``
+ shell environment variable, you will need to specify the
+ ``PythonPath`` directive in your Apache configuration file.
-3. Copy the file ``django_src/django/bin/`` to somewhere on your
- system path, such as ``/usr/local/bin`` (Unix) or ``C:\Python24\Scripts``
+4. Copy the file ``django-trunk/django/bin/`` to somewhere on
+ your system path, such as ``/usr/local/bin`` (Unix) or ``C:\Python24\Scripts``
(Windows). This step simply lets you type ```` from within
any directory, rather than having to qualify the command with the full path
to the file.
-You *don't* have to run ``python install``, because that command
-takes care of steps 2 and 3 for you.
+You *don't* have to run ``python install``, because you've already
+carried out the equivalent actions in steps 3 and 4.
When you want to update your copy of the Django source code, just run the
-command ``svn update`` from within the ``django`` directory. When you do this,
-Subversion will automatically download any changes.
+command ``svn update`` from within the ``django-trunk`` directory. When you do
+this, Subversion will automatically download any changes.
.. _`download page`:
.. _Subversion:
+.. _from the Control Panel:

0 comments on commit 518bc15

Please sign in to comment.