Repository files navigation
python manage.py runserver
pip install -r requirments.txt --> This will install the dependencies
pip freeze > requirements.txt --> This will update requirments.txt with your current virtualenv's libraries
in /polls/views.py --> from django.views import generic
DetailView template --> <app name>/<model name>_detail.html
ListView template --> <app name>/<model name>_list.html
python manage.py test <app name> <-- run the test found in the <app name>
response.context(<context object name>) will return the objects used to
render the view
response.content will return the html (or json etc)
move the polls directory into a django-polls directory ousite of mysite
create a file django-polls/README.rst
create django-polls/setup.py
create django-polls/MANIFEST.in <-- has recursive-include config commands
cd into django-polls and run: python setup.py sdist <-- this builds the
package
pip install --user django-polls/dist/django-polls-0.1.tar.gz (remove --user to
work with virtualenvwrapper
You can’t perform that action at this time.