码迷,mamicode.com
首页 > 其他好文 > 详细

Django basic command

时间:2015-07-28 06:40:44      阅读:83      评论:0      收藏:0      [点我收藏+]

标签:

https://docs.djangoproject.com/en/1.8/intro/tutorial01/

1. get django version

python -c "import django; print(django.get_version())"

2. run server

python manage.py runserver

3. create a project

django-admin startproject [project name]

4. create a app

python manage.py startapp [app name]

5. create a migration file (not changing database, just create a file)

 python manage.py makemigrations

6. apply migration (update database schema)

 python manage.py migrate

 

Django basic command

标签:

原文地址:http://www.cnblogs.com/phoenix13suns/p/4681713.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!