Skip to content

Contribution Info

Gary Gao edited this page Jun 2, 2016 · 14 revisions

Contribution Info

Coding Style

Before you commit, you should check and fix coding style to make code consistent and readable.

  • manually check coding style
# cd to project root dir
$ flake8 --first .
  • automatically check coding style when git commit
# install git pre commit hook
$ flake8 --install-hook
$ git config flake8.strict true

git commit will fail if the code can't pass coding style check.

Docs

Development Tips

How to Update Models to Database ?

$ python manage.py makemigrations
$ python manage.py migrate

Using Django Shell to Debug

$ python manage.py shell

see more detail

Clone this wiki locally