Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
D
django
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
Batuhan Osman TASKAYA
django
Commits
a8e492bc
Unverified
Kaydet (Commit)
a8e492bc
authored
Ock 12, 2018
tarafından
Tim Graham
Kaydeden (comit)
GitHub
Ock 12, 2018
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Removed note in tutorial about bypassing manage.py.
This isn't relevant for beginners.
üst
1e81a4b8
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
0 additions
and
22 deletions
+0
-22
tutorial02.txt
docs/intro/tutorial02.txt
+0
-22
No files found.
docs/intro/tutorial02.txt
Dosyayı görüntüle @
a8e492bc
...
@@ -381,28 +381,6 @@ We're using this instead of simply typing "python", because :file:`manage.py`
...
@@ -381,28 +381,6 @@ We're using this instead of simply typing "python", because :file:`manage.py`
sets the ``DJANGO_SETTINGS_MODULE`` environment variable, which gives Django
sets the ``DJANGO_SETTINGS_MODULE`` environment variable, which gives Django
the Python import path to your :file:`mysite/settings.py` file.
the Python import path to your :file:`mysite/settings.py` file.
.. admonition:: Bypassing manage.py
If you'd rather not use :file:`manage.py`, no problem. Just set the
:envvar:`DJANGO_SETTINGS_MODULE` environment variable to
``mysite.settings``, start a plain Python shell, and set up Django:
.. code-block:: pycon
>>> import django
>>> django.setup()
If this raises an :exc:`AttributeError`, you're probably using
a version of Django that doesn't match this tutorial version. You'll want
to either switch to the older tutorial or the newer Django version.
You must run ``python`` from the same directory :file:`manage.py` is in,
or ensure that directory is on the Python path, so that ``import mysite``
works.
For more information on all of this, see the :doc:`django-admin
documentation </ref/django-admin>`.
Once you're in the shell, explore the :doc:`database API </topics/db/queries>`::
Once you're in the shell, explore the :doc:`database API </topics/db/queries>`::
>>> from polls.models import Question, Choice # Import the model classes we just wrote.
>>> from polls.models import Question, Choice # Import the model classes we just wrote.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment