Ticket #19344: 19344.diff

File 19344.diff, 3.6 KB (added by Tim Graham, 12 years ago)
  • docs/faq/troubleshooting.txt

    diff --git a/docs/faq/troubleshooting.txt b/docs/faq/troubleshooting.txt
    index f984be4..a961096 100644
    a b Troubleshooting  
    55This page contains some advice about errors and problems commonly encountered
    66during the development of Django applications.
    77
     8.. _troubleshooting-django-admin:
     9
     10Problems running django-admin.py
     11--------------------------------
     12
    813"command not found: django-admin.py"
    9 ------------------------------------
     14====================================
    1015
    1116:doc:`django-admin.py </ref/django-admin>` should be on your system path if you
    1217installed Django via ``python setup.py``. If it's not on your path, you can
    1318find it in ``site-packages/django/bin``, where ``site-packages`` is a directory
    1419within your Python installation. Consider symlinking to :doc:`django-admin.py
    1520</ref/django-admin>` from some place on your path, such as
    16 :file:`/usr/local/bin`.
    17  No newline at end of file
     21:file:`/usr/local/bin`.
     22
     23Script name may differ in distribution packages
     24===============================================
     25
     26If you installed Django using a Linux distribution's package manager
     27(e.g. ``apt-get`` or ``yum``) ``django-admin.py`` may have been renamed to
     28``django-admin``; use that instead.
     29
     30Mac OS X permissions
     31====================
     32
     33If you're using Mac OS X, you may see the message "permission denied" when
     34you try to run ``django-admin.py startproject``. This is because, on
     35Unix-based systems like OS X, a file must be marked as "executable" before it
     36can be run as a program. To do this, open Terminal.app and navigate (using
     37the ``cd`` command) to the directory where :doc:`django-admin.py
     38</ref/django-admin>` is installed, then run the command
     39``sudo chmod +x django-admin.py``.
     40
     41Running virtualenv on Windows
     42=============================
     43
     44If you used virtualenv_ to :ref:`install Django <installing-official-release>`
     45on Windows, you may get an ``ImportError`` when you try to run
     46``django-admin.py startproject``. This is because Windows does not run the
     47Python interpreter from your virtual environment unless you invoke it
     48directly. Instead, prefix all commands that use .py files with ``python`` and
     49use the full path to the file, like so:
     50``python C:\pythonXY\Scripts\django-admin.py startproject mysite``.
     51
     52.. _virtualenv: http://www.virtualenv.org/
  • docs/intro/tutorial01.txt

    diff --git a/docs/intro/tutorial01.txt b/docs/intro/tutorial01.txt
    index 9913b21..5275cc5 100644
    a b code, then run the following command:  
    5353   django-admin.py startproject mysite
    5454
    5555This will create a ``mysite`` directory in your current directory. If it didn't
    56 work, see :doc:`Troubleshooting </faq/troubleshooting>`.
    57 
    58 .. admonition:: Script name may differ in distribution packages
    59 
    60    If you installed Django using a Linux distribution's package manager
    61    (e.g. apt-get or yum) ``django-admin.py`` may have been renamed to
    62    ``django-admin``. You may continue through this documentation by omitting
    63    ``.py`` from each command.
    64 
    65 .. admonition:: Mac OS X permissions
    66 
    67    If you're using Mac OS X, you may see the message "permission denied" when
    68    you try to run ``django-admin.py startproject``. This is because, on
    69    Unix-based systems like OS X, a file must be marked as "executable" before it
    70    can be run as a program. To do this, open Terminal.app and navigate (using
    71    the ``cd`` command) to the directory where :doc:`django-admin.py
    72    </ref/django-admin>` is installed, then run the command
    73    ``sudo chmod +x django-admin.py``.
     56work, see :ref:`Troubleshooting <troubleshooting-django-admin>`.
    7457
    7558.. note::
    7659
Back to Top